fix escaping of $file variable in runners using script property

pull/483/head
nightwing 2018-02-10 21:45:11 +04:00
rodzic 1ecdf902a4
commit 6fd7bb1981
4 zmienionych plików z 12 dodań i 12 usunięć

Wyświetl plik

@ -2,15 +2,15 @@
"script": [ "script": [
"set -e", "set -e",
"if ! [ \"$debug\" == true ]; then ", "if ! [ \"$debug\" == true ]; then ",
" node $file $args", " node \"$file\" $args",
"elif \"$(node -p 'parseInt(process.version.slice(1)) < 7')\" == true; then", "elif \"$(node -p 'parseInt(process.version.slice(1)) < 7')\" == true; then",
" FLAGS=\"--nocrankshaft --nolazy --debug-brk=$debugport\"", " FLAGS=\"--nocrankshaft --nolazy --debug-brk=$debugport\"",
" if node --nodead_code_elimination -e '' &> /dev/null; then", " if node --nodead_code_elimination -e '' &> /dev/null; then",
" FLAGS=\"$FLAGS --nodead_code_elimination\"", " FLAGS=\"$FLAGS --nodead_code_elimination\"",
" fi", " fi",
" node $FLAGS $file $args", " node $FLAGS \"$file\" $args",
"else", "else",
" node --inspect-brk=$debugport $file $args", " node --inspect-brk=$debugport \"$file\" $args",
"fi" "fi"
], ],
"debugger": "v8", "debugger": "v8",

Wyświetl plik

@ -2,13 +2,13 @@
"script" : [ "script" : [
"set -e", "set -e",
"if [ \"$debug\" == true ]; then ", "if [ \"$debug\" == true ]; then ",
"/usr/bin/g++ -ggdb3 -std=c++11 $file -o $file.o", "/usr/bin/g++ -ggdb3 -std=c++11 \"$file\" -o \"$file.o\"",
"chmod 755 \"$file.o\"", "chmod 755 \"$file.o\"",
"node $HOME/.c9/bin/c9gdbshim.js \"$file.o\" $args", "node $HOME/.c9/bin/c9gdbshim.js \"$file.o\" $args",
"else", "else",
"/usr/bin/g++ -std=c++11 $file -o $file.o", "/usr/bin/g++ -std=c++11 \"$file\" -o \"$file.o\"",
"chmod 755 $file.o", "chmod 755 \"$file.o\"",
"$file.o $args", "\"$file.o\" $args",
"fi" "fi"
], ],
"info": "Running $file", "info": "Running $file",

Wyświetl plik

@ -2,15 +2,15 @@
"script": [ "script": [
"set -e", "set -e",
"if ! [ \"$debug\" == true ]; then ", "if ! [ \"$debug\" == true ]; then ",
" node $file $args", " node \"$file\" $args",
"elif node --debug -e '' &> /dev/null; then", "elif node --debug -e '' &> /dev/null; then",
" FLAGS=\"--nocrankshaft --nolazy --debug-brk=$debugport\"", " FLAGS=\"--nocrankshaft --nolazy --debug-brk=$debugport\"",
" if node --nodead_code_elimination -e '' &> /dev/null; then", " if node --nodead_code_elimination -e '' &> /dev/null; then",
" FLAGS=\"$FLAGS --nodead_code_elimination\"", " FLAGS=\"$FLAGS --nodead_code_elimination\"",
" fi", " fi",
" node $FLAGS $file $args", " node $FLAGS \"$file\" $args",
"else", "else",
" node --inspect-brk=$debugport $file $args", " node --inspect-brk=$debugport \"$file\" $args",
"fi" "fi"
], ],
"debugger": "v8", "debugger": "v8",

Wyświetl plik

@ -1,9 +1,9 @@
{ {
"script": [ "script": [
"if [ \"$debug\" == true ]; then ", "if [ \"$debug\" == true ]; then ",
" python2 -m ikpdb --ikpdb-port=15471 --ikpdb-working-directory=$project_path $file $args", " python2 -m ikpdb --ikpdb-port=15471 --ikpdb-working-directory=$project_path \"$file\" $args",
"else", "else",
" python2 $file $args", " python2 \"$file\" $args",
"fi", "fi",
"checkExitCode() {", "checkExitCode() {",
" if [ $1 ] && [ \"$debug\" == true ]; then ", " if [ $1 ] && [ \"$debug\" == true ]; then ",