diff options
author | Otavio Salvador <otavio@ossystems.com.br> | 2025-01-29 15:44:31 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2025-01-29 15:44:31 -0300 |
commit | cb7b64c67e0d664cb6665a634755004946e9e86e (patch) | |
tree | 1ea207bb573280358a25112e311225329fdc6128 | |
parent | 9853cc39c849451993a62d22fdd30b891e8e3230 (diff) | |
parent | 0602af4c78ef5a6ee5e64d2cf9202c22aa636b25 (diff) | |
download | meta-freescale-cb7b64c67e0d664cb6665a634755004946e9e86e.tar.gz |
Merge pull request #2087 from Villemoes/sort-license
scripts: avoid pointless LICENSE churn
-rwxr-xr-x | scripts/generate-license-file | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/scripts/generate-license-file b/scripts/generate-license-file index 2f4e9766..02b45ab3 100755 --- a/scripts/generate-license-file +++ b/scripts/generate-license-file | |||
@@ -1,5 +1,7 @@ | |||
1 | #!/bin/bash | 1 | #!/bin/bash |
2 | 2 | ||
3 | export LC_ALL=C | ||
4 | |||
3 | # Create or clear the LICENSE file | 5 | # Create or clear the LICENSE file |
4 | echo "# License Information" > LICENSE | 6 | echo "# License Information" > LICENSE |
5 | echo "" >> LICENSE | 7 | echo "" >> LICENSE |
@@ -7,7 +9,7 @@ echo "This file lists all licenses used by recipes in the meta-freescale layer." | |||
7 | echo "" >> LICENSE | 9 | echo "" >> LICENSE |
8 | 10 | ||
9 | # Find all .bb and .inc files and extract license information | 11 | # Find all .bb and .inc files and extract license information |
10 | find . -type f \( -name "*.bb" -o -name "*.inc" \) | while read -r file; do | 12 | find . -type f \( -name "*.bb" -o -name "*.inc" \) | sort | while read -r file; do |
11 | # Extract the license line from each recipe file, if it exists | 13 | # Extract the license line from each recipe file, if it exists |
12 | license_line=$(grep -i "^LICENSE" "$file") | 14 | license_line=$(grep -i "^LICENSE" "$file") |
13 | if [ -n "$license_line" ]; then | 15 | if [ -n "$license_line" ]; then |