generated from Templates/Baseline
adds setCode helper (#6)
#### 📖 Summary - adds `setcode` parameter in `install-devrutime` sctiüz #### 📑 Test Plan > 💡 Select your test plan for the code changes. - [x] Tested via Drone.io pipeline - [ ] Custom test - [ ] No test plan ##### Details / Justification <!-- Add your test details or justification for missing tests here. --> #### 📚 Additional Notes <!-- A place for additional detail notes. --> Co-authored-by: OCram85 <marco.blessing@googlemail.com> Reviewed-on: CodeServer/Container#6
This commit is contained in:
parent
e73eabc2c5
commit
494f236ca7
|
@ -15,6 +15,8 @@ function showHelp() {
|
||||||
powershell Installs latest PowerShell LTS version.
|
powershell Installs latest PowerShell LTS version.
|
||||||
-h Prints this help messagee.
|
-h Prints this help messagee.
|
||||||
disablemotd Disables hint in new bash terminal
|
disablemotd Disables hint in new bash terminal
|
||||||
|
setcode Sets VS Code user setting with basic (Fira Code)
|
||||||
|
|
||||||
Example 1: install-devruntime dotnet
|
Example 1: install-devruntime dotnet
|
||||||
Example 2: install devruntime golang nodejs
|
Example 2: install devruntime golang nodejs
|
||||||
HELP
|
HELP
|
||||||
|
@ -123,6 +125,23 @@ function instPwsh() {
|
||||||
echo "done." "PowerShell"
|
echo "done." "PowerShell"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function setCodeSettings() {
|
||||||
|
CODEFILE="$HOME/data/User/settings.json"
|
||||||
|
say "Setting VScode base settings.($CODEFILE)"
|
||||||
|
cat <<EOF | tee "$CODEFILE"
|
||||||
|
{
|
||||||
|
"workbench.colorTheme": "One Dark Pro Darker",
|
||||||
|
"window.menuBarVisibility": "classic",
|
||||||
|
"editor.fontFamily": "'FiraCode Nerd Font', 'FiraCode NF', Consolas, 'Courier New', monospace",
|
||||||
|
"terminal.integrated.fontFamily": "'FiraCode Nerd Font Mono', 'FiraCode NFM', Consolas, monospace",
|
||||||
|
"editor.fontLigatures": true,
|
||||||
|
"workbench.iconTheme": "vscode-icons",
|
||||||
|
"extensions.autoUpdate": false,
|
||||||
|
"git.confirmSync": false
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
}
|
||||||
|
|
||||||
function main() {
|
function main() {
|
||||||
if [[ "$#" == "0" ]]; then
|
if [[ "$#" == "0" ]]; then
|
||||||
showHelp
|
showHelp
|
||||||
|
@ -144,6 +163,9 @@ function main() {
|
||||||
elif [[ "$i" == "disablemotd" ]]; then
|
elif [[ "$i" == "disablemotd" ]]; then
|
||||||
disableMotd
|
disableMotd
|
||||||
exit 0
|
exit 0
|
||||||
|
elif [[ "$i" == "setcode" ]]; then
|
||||||
|
setCodeSettings
|
||||||
|
exit 0
|
||||||
else
|
else
|
||||||
sayE "Unknown parameter value given!($i)."
|
sayE "Unknown parameter value given!($i)."
|
||||||
showHelp
|
showHelp
|
||||||
|
|
|
@ -1,3 +1,3 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
complete -W "disablemotd dotnet golang nodejs powershell -h" install-devruntime
|
complete -W "disablemotd dotnet golang nodejs powershell setcode -h" install-devruntime
|
||||||
|
|
Loading…
Reference in New Issue