Add quotes around $dir/$persist_dir vars where needed (#1948)

* Add quotes around $dir var where needed

* Add quotes around $dir vars where needed
This commit is contained in:
Ross Smith II 2018-01-26 08:43:48 -08:00 committed by Richard Kuhnt
parent fc73751ba1
commit 822c4bee45
24 changed files with 36 additions and 27 deletions

View File

@ -6,7 +6,7 @@
"hash": "fd0617585b88517a3d41d3d206c1dc38058c57b90dfd88c278049a41aeb5be38", "hash": "fd0617585b88517a3d41d3d206c1dc38058c57b90dfd88c278049a41aeb5be38",
"bin": "ack.bat", "bin": "ack.bat",
"depends": "perl", "depends": "perl",
"pre_install": "Set-Content -Value '@perl.exe %~dp0ack-single-file %*' -Path $dir\\ack.bat", "pre_install": "Set-Content -Value '@perl.exe %~dp0ack-single-file %*' -Path \"$dir\\ack.bat\"",
"checkver": { "checkver": {
"url": "https://beyondgrep.com/install/", "url": "https://beyondgrep.com/install/",
"re": "The current stable version of ack is version ([\\d.]+)," "re": "The current stable version of ack is version ([\\d.]+),"

View File

@ -17,6 +17,6 @@
"bzip2.exe", "bzip2.exe",
"bzip2recover.exe" "bzip2recover.exe"
], ],
"pre_install": "cp $dir\\bzip2.exe $dir\\bunzip2.exe; cp $dir\\bzip2.exe $dir\\bzcat.exe", "pre_install": "cp \"$dir\\bzip2.exe\" \"$dir\\bunzip2.exe\"; cp \"$dir\\bzip2.exe\" \"$dir\\bzcat.exe\"",
"checkver": "The current version is <b>([\\d.]+)" "checkver": "The current version is <b>([\\d.]+)"
} }

View File

@ -10,8 +10,8 @@
}, },
"env_add_path": "home\\vendor\\bin", "env_add_path": "home\\vendor\\bin",
"pre_install": " "pre_install": "
echo 'if($args -eq \"selfupdate\" -or $args -eq \"self-update\") { & scoop update composer }' | out-file $dir\\composer.ps1 echo 'if($args -eq \"selfupdate\" -or $args -eq \"self-update\") { & scoop update composer }' | out-file \"$dir\\composer.ps1\"
echo 'else { & php (join-path \"$psscriptroot\" \"composer.phar\") @args }' | out-file $dir\\composer.ps1 -append echo 'else { & php (join-path \"$psscriptroot\" \"composer.phar\") @args }' | out-file \"$dir\\composer.ps1\" -append
", ",
"post_install": " "post_install": "
$och = \"$env:APPDATA\\Composer\" $och = \"$env:APPDATA\\Composer\"

View File

@ -7,7 +7,7 @@
"installer": { "installer": {
"args": [ "args": [
"/S", "/S",
"/D=$dir" "/D=\"$dir\""
] ]
}, },
"bin": [ "bin": [

View File

@ -23,7 +23,7 @@
"installer": { "installer": {
"args": [ "args": [
"/S", "/S",
"/D=$dir" "/D=\"$dir\""
] ]
}, },
"uninstaller": { "uninstaller": {

View File

@ -7,7 +7,7 @@
"extract_dir": "PyGitUp-1.4.6", "extract_dir": "PyGitUp-1.4.6",
"depends": "python", "depends": "python",
"post_install": " "post_install": "
pushd $dir pushd \"$dir\"
try { try {
scoop reset python scoop reset python
iex \"$(scoop which python) setup.py install\" iex \"$(scoop which python) setup.py install\"

View File

@ -8,7 +8,10 @@
} }
}, },
"installer": { "installer": {
"args": "/S /D=$dir" "args": [
"/S",
"/D=\"$dir\""
]
}, },
"uninstaller": { "uninstaller": {
"file": "Uninstall.exe", "file": "Uninstall.exe",

View File

@ -7,7 +7,7 @@
"installer": { "installer": {
"args": [ "args": [
"/S", "/S",
"/D=$dir" "/D=\"$dir\""
] ]
}, },
"uninstaller": { "uninstaller": {

View File

@ -16,7 +16,7 @@
"file": "julia-installer.exe", "file": "julia-installer.exe",
"args": [ "args": [
"/S", "/S",
"/D=$dir" "/D=\"$dir\""
] ]
}, },
"uninstaller": { "uninstaller": {

View File

@ -13,7 +13,10 @@
} }
}, },
"installer": { "installer": {
"args": "/S /D=$dir" "args": [
"/S",
"/D=\"$dir\""
]
}, },
"uninstaller": { "uninstaller": {
"file": "Uninstall.exe", "file": "Uninstall.exe",

View File

@ -6,6 +6,6 @@
"hash": "552bc68afd2ff9a5de88f26d76f55dd8697cf6082c6afb01b3d1a9942f4d3ee0", "hash": "552bc68afd2ff9a5de88f26d76f55dd8697cf6082c6afb01b3d1a9942f4d3ee0",
"bin": "lynx.ps1", "bin": "lynx.ps1",
"pre_install": " "pre_install": "
\"$dir\\lynx.exe --cfg=$dir\\lynx.cfg\" | out-file -enc oem $dir\\lynx.ps1 \"\\\"$dir\\lynx.exe\\\" --cfg=\\\"$dir\\lynx.cfg\\\"\" | out-file -enc oem \"$dir\\lynx.ps1\"
" "
} }

View File

@ -6,7 +6,7 @@
"hash": "c012456b9f29e488b0e9a688aa43a34326dd573f9e99765cbdac2b81a4bc1060", "hash": "c012456b9f29e488b0e9a688aa43a34326dd573f9e99765cbdac2b81a4bc1060",
"bin": "nano.exe", "bin": "nano.exe",
"extract_dir": "nano-2.5.3-win32", "extract_dir": "nano-2.5.3-win32",
"post_install": "if (-not (Test-Path ~/nano.rc)) { Copy-Item $dir/nano.rc ~/nano.rc }", "post_install": "if (-not (Test-Path ~/nano.rc)) { Copy-Item \"$dir/nano.rc\" ~/nano.rc }",
"checkver": "Latest Version\\s+([\\d.]+)", "checkver": "Latest Version\\s+([\\d.]+)",
"notes": " "notes": "
You can configure nano editor by editing the configuration file nano.rc You can configure nano editor by editing the configuration file nano.rc

View File

@ -16,7 +16,7 @@
"extract_dir": "nim-0.17.2", "extract_dir": "nim-0.17.2",
"post_install": " "post_install": "
# Copy Nimble package # Copy Nimble package
Copy-Item -Recurse $dir\\dist\\nimble\\src\\nimblepkg $dir\\bin Copy-Item -Recurse \"$dir\\dist\\nimble\\src\\nimblepkg\" \"$dir\\bin\"
", ",
"bin": [ "bin": [
"bin\\c2nim.exe", "bin\\c2nim.exe",

View File

@ -6,7 +6,10 @@
"hash": "5dbe89981a8d567e5b9b935fbf8019885e7347f45c5af69cab21e8dcafee3393", "hash": "5dbe89981a8d567e5b9b935fbf8019885e7347f45c5af69cab21e8dcafee3393",
"extract_dir": "nmap", "extract_dir": "nmap",
"installer": { "installer": {
"args": "/S /D=$dir" "args": [
"/S",
"/D=\"$dir\""
]
}, },
"uninstaller": { "uninstaller": {
"file": "Uninstall.exe", "file": "Uninstall.exe",

View File

@ -24,7 +24,7 @@
], ],
"post_install": " "post_install": "
# Set npm prefix to install modules inside bin and npm cache so they persist # Set npm prefix to install modules inside bin and npm cache so they persist
Set-Content -Value \"prefix=$persist_dir\\bin`ncache=$persist_dir\\cache\" -Path $dir\\node_modules\\npm\\npmrc Set-Content -Value \"prefix=\\\"$persist_dir\\bin\\\"`ncache=\\\"$persist_dir\\cache\\\"\" -Path \"$dir\\node_modules\\npm\\npmrc\"
", ",
"checkver": { "checkver": {
"url": "https://nodejs.org/download/chakracore-release/index.json", "url": "https://nodejs.org/download/chakracore-release/index.json",

View File

@ -24,7 +24,7 @@
], ],
"post_install": " "post_install": "
# Set npm prefix to install modules inside bin and npm cache so they persist # Set npm prefix to install modules inside bin and npm cache so they persist
Set-Content -Value \"prefix=$persist_dir\\bin`ncache=$persist_dir\\cache\" -Path $dir\\node_modules\\npm\\npmrc Set-Content -Value \"prefix=\\\"$persist_dir\\bin\\\"`ncache=\\\"$persist_dir\\cache\\\"\" -Path \"$dir\\node_modules\\npm\\npmrc\"
", ",
"checkver": { "checkver": {
"url": "https://nodejs.org/en/download/", "url": "https://nodejs.org/en/download/",

View File

@ -24,7 +24,7 @@
], ],
"post_install": " "post_install": "
# Set npm prefix to install modules inside bin and npm cache so they persist # Set npm prefix to install modules inside bin and npm cache so they persist
Set-Content -Value \"prefix=$persist_dir\\bin`ncache=$persist_dir\\cache\" -Path $dir\\node_modules\\npm\\npmrc Set-Content -Value \"prefix=\\\"$persist_dir\\bin\\\"`ncache=\\\"$persist_dir\\cache\\\"\" -Path \"$dir\\node_modules\\npm\\npmrc\"
", ",
"checkver": { "checkver": {
"url": "https://nodejs.org/dist/latest/", "url": "https://nodejs.org/dist/latest/",

View File

@ -26,12 +26,12 @@
"architecture": { "architecture": {
"64bit": { "64bit": {
"pre_install": "if(!(test-path \"$dir\\settings.txt\")) { "pre_install": "if(!(test-path \"$dir\\settings.txt\")) {
write-output \"root: $persist_dir\\nodejs`r`narch: 64`r`nproxy: none\" | Out-File -encoding \"ASCII\" $dir\\settings.txt write-output \"root: $persist_dir\\nodejs`r`narch: 64`r`nproxy: none\" | Out-File -encoding \"ASCII\" \"$dir\\settings.txt\"
}" }"
}, },
"32bit": { "32bit": {
"pre_install": "if(!(test-path \"$dir\\settings.txt\")) { "pre_install": "if(!(test-path \"$dir\\settings.txt\")) {
write-output \"root: $persist_dir\\nodejs`r`narch: 32`r`nproxy: none\" | Out-File -encoding \"ASCII\" $dir\\settings.txt write-output \"root: $persist_dir\\nodejs`r`narch: 32`r`nproxy: none\" | Out-File -encoding \"ASCII\" \"$dir\\settings.txt\"
}" }"
} }
}, },

View File

@ -16,7 +16,7 @@
# enable standard idiomatic access to user's home directory # enable standard idiomatic access to user's home directory
## remove HomeDir section from portable.perl (disables Portable.pm override of File::HomeDir) ## remove HomeDir section from portable.perl (disables Portable.pm override of File::HomeDir)
## NOTE: conversion to byte[] avoids adding an extra trailing newline to the output file ## NOTE: conversion to byte[] avoids adding an extra trailing newline to the output file
[byte[]][char[]]((Get-Content -raw $dir\\portable.perl) -replace \"(?ms)^HomeDir:.*?^(?=\\S)\",\"\") | Set-Content $dir\\portable.perl -encoding byte [byte[]][char[]]((Get-Content -raw \"$dir\\portable.perl\") -replace \"(?ms)^HomeDir:.*?^(?=\\S)\",\"\") | Set-Content \"$dir\\portable.perl\" -encoding byte
", ",
"env_add_path": [ "env_add_path": [
"perl\\site\\bin", "perl\\site\\bin",

4
r.json
View File

@ -6,12 +6,12 @@
"64bit": { "64bit": {
"url": "https://cran.rstudio.com/bin/windows/base/R-3.4.3-win.exe", "url": "https://cran.rstudio.com/bin/windows/base/R-3.4.3-win.exe",
"hash": "7d46cd1de979cd0ef1a6e8de0e1a35223d1304d8953e4cd0d414153852ce684b", "hash": "7d46cd1de979cd0ef1a6e8de0e1a35223d1304d8953e4cd0d414153852ce684b",
"pre_install": "copy-item -recurse $dir\\bin\\x64 $dir\\bin\\curr_arch" "pre_install": "copy-item -recurse \"$dir\\bin\\x64\" \"$dir\\bin\\curr_arch\""
}, },
"32bit": { "32bit": {
"url": "https://cran.rstudio.com/bin/windows/base/R-3.4.3-win.exe", "url": "https://cran.rstudio.com/bin/windows/base/R-3.4.3-win.exe",
"hash": "7d46cd1de979cd0ef1a6e8de0e1a35223d1304d8953e4cd0d414153852ce684b", "hash": "7d46cd1de979cd0ef1a6e8de0e1a35223d1304d8953e4cd0d414153852ce684b",
"pre_install": "copy-item -recurse $dir\\bin\\i386 $dir\\bin\\curr_arch" "pre_install": "copy-item -recurse \"$dir\\bin\\i386\" \"$dir\\bin\\curr_arch\""
} }
}, },
"innosetup": true, "innosetup": true,

View File

@ -15,7 +15,7 @@
"devkit" "devkit"
], ],
"env_add_path": "bin", "env_add_path": "bin",
"post_install": "pushd $dir\\devkit;ruby dk.rb init > $null;echo \"- $dir\" | out-file config.yml -a -enc default; ruby dk.rb install;popd;", "post_install": "pushd \"$dir\\devkit\";ruby dk.rb init > $null;echo \"- $dir\" | out-file config.yml -a -enc default; ruby dk.rb install;popd;",
"checkver": { "checkver": {
"url": "https://bintray.com/package/generalTab?pkgPath=/oneclick/rubyinstaller/rubyinstaller", "url": "https://bintray.com/package/generalTab?pkgPath=/oneclick/rubyinstaller/rubyinstaller",
"re": "rubyinstaller/(1.9[\\d.]+-p[\\d]+)" "re": "rubyinstaller/(1.9[\\d.]+-p[\\d]+)"

View File

@ -17,7 +17,7 @@
"installer": { "installer": {
"args": [ "args": [
"/S", "/S",
"/D=$dir" "/D=\"$dir\""
] ]
}, },
"checkver": { "checkver": {

View File

@ -8,7 +8,7 @@
"installer": { "installer": {
"args": [ "args": [
"-s", "-s",
"-d$dir" "-d\"$dir\""
] ]
}, },
"checkver": { "checkver": {

View File

@ -22,7 +22,7 @@
}, },
"bin": "wget.exe", "bin": "wget.exe",
"depends": "cacert", "depends": "cacert",
"post_install": "\"ca_certificate=$(appdir cacert)\\current\\cacert.pem\" | out-file $dir\\wget.ini -encoding default", "post_install": "\"ca_certificate=$(appdir cacert)\\current\\cacert.pem\" | out-file \"$dir\\wget.ini\" -encoding default",
"checkver": "<title>GNU Wget ([\\d.]+) for Windows", "checkver": "<title>GNU Wget ([\\d.]+) for Windows",
"autoupdate": { "autoupdate": {
"architecture": { "architecture": {