Improved generator.sh script to generate file to the specified file
This commit is contained in:
1 parent
22b7797a83
commit
a7b2aa1014
2 files changed
+112
-17
No files matched your search
+5
-5
@@ -14,12 +14,12 @@
|
||||
|
||||
#!/bin/bash
|
||||
|
||||
echo "#include \"globals.h\"" > "generated.h"
|
||||
echo "" >> "generated.h"
|
||||
echo "static const char* generated_source = \"\"" >> "generated.h"
|
||||
echo "#include \"globals.h\"" > $2
|
||||
echo "" >> $2
|
||||
echo "static const char* generated_source = \"\"" >> $2
|
||||
while read line
|
||||
do
|
||||
echo "\"$line\n\"" >> "generated.h"
|
||||
echo "\"$line\n\"" >> $2
|
||||
done < $1
|
||||
echo ";" >> "generated.h"
|
||||
echo ";" >> $2
|
||||
|
||||
Reference in new issue
Block a user