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.
2 parents ab1fbdd + 87b6d1b commit 520d196Copy full SHA for 520d196
extractScriptMetadata.sh
@@ -1,2 +1,2 @@
1
#!/bin/bash
2
-sed -e '/./{H;$!d;}' -e 'x;/UserScript/!d;' $1 | awk '!/^$/' > ${1/.user./.meta.}
+awk '/./; /\/UserScript/ { exit }' "$1" > "${1/.user./.meta.}"
0 commit comments