We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 42f6f00 commit 9eb0138Copy full SHA for 9eb0138
1 file changed
enterprise/scripts/add-license.sh
@@ -47,7 +47,11 @@ remove_license_headers() {
47
48
# Remove all lines from any occurrence of "IMPORTANT LICENSE NOTICE"
49
# through "Copyright (c) 2026 Cosmos Labs US Inc."
50
- sed '/\/\/ IMPORTANT LICENSE NOTICE/,/\/\/ Copyright (c) 2026 Cosmos Labs US Inc\./d' "$file" > "$tmpfile"
+ if grep -qF "// Copyright (c) 2026 Cosmos Labs US Inc." "$file"; then
51
+ sed '/\/\/ IMPORTANT LICENSE NOTICE/,/\/\/ Copyright (c) 2026 Cosmos Labs US Inc\./d' "$file" > "$tmpfile"
52
+ else
53
+ cp "$file" "$tmpfile"
54
+ fi
55
56
# Remove any blank lines at the start of file
57
sed -i.bak '1{/^$/d;}' "$tmpfile"
0 commit comments