rust: add missing SPDX-License-Identifier tag
This adds a missing `SPDX-License-Identifier` tag, fixing CI.
This commit is contained in:
parent
49c55089d2
commit
a1ecc3d583
@ -3,17 +3,17 @@
|
|||||||
# can be run without building it.
|
# can be run without building it.
|
||||||
set -euo pipefail
|
set -euo pipefail
|
||||||
|
|
||||||
echo -n "Checking for tabs..."
|
echo -n "checking for tabs... "
|
||||||
(git grep -E '^ +' -- '*.[ch]' || true) > tabdamage.txt
|
(git grep -E '^ +' -- '*.[ch]' || true) > tabdamage.txt
|
||||||
if test -s tabdamage.txt; then
|
if test -s tabdamage.txt; then
|
||||||
echo "Error: tabs in .[ch] files:"
|
echo "Error: tabs in .[ch] files:"
|
||||||
cat tabdamage.txt
|
cat tabdamage.txt
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
rm -v tabdamage.txt
|
rm tabdamage.txt
|
||||||
echo "ok"
|
echo "ok"
|
||||||
|
|
||||||
echo -n "checking rustfmt..."
|
echo -n "checking rustfmt... "
|
||||||
for crate in $(find -iname Cargo.toml); do
|
for crate in $(find -iname Cargo.toml); do
|
||||||
if ! cargo fmt --manifest-path ${crate} -- --check; then
|
if ! cargo fmt --manifest-path ${crate} -- --check; then
|
||||||
echo "cargo fmt failed; run: cd $(dirname ${crate}) && cargo fmt" 1>&2
|
echo "cargo fmt failed; run: cd $(dirname ${crate}) && cargo fmt" 1>&2
|
||||||
@ -23,7 +23,7 @@ done
|
|||||||
echo "ok"
|
echo "ok"
|
||||||
|
|
||||||
ident='SPDX-License-Identifier:'
|
ident='SPDX-License-Identifier:'
|
||||||
echo -n "checking \"$ident\"..."
|
echo -n "checking \"$ident\"... "
|
||||||
git ls-files '*.rs' | while read f; do
|
git ls-files '*.rs' | while read f; do
|
||||||
if ! grep -qF "$ident" $f; then
|
if ! grep -qF "$ident" $f; then
|
||||||
echo "error: File $f: Missing $ident" 1>&2
|
echo "error: File $f: Missing $ident" 1>&2
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
//! Rust portion of rpmostreed-deployment-utils.cxx
|
//! Rust portion of rpmostreed-deployment-utils.cxx
|
||||||
|
|
||||||
|
// SPDX-License-Identifier: Apache-2.0 OR MIT
|
||||||
|
|
||||||
use crate::cxxrsutil::*;
|
use crate::cxxrsutil::*;
|
||||||
use std::pin::Pin;
|
use std::pin::Pin;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user