-
-
Notifications
You must be signed in to change notification settings - Fork 182
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
create specific vscode user-level unit file
- Loading branch information
Showing
4 changed files
with
36 additions
and
20 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
#!/usr/bin/env bash | ||
|
||
# SCRIPT VERSION | ||
USER_SETUP_VER=1 | ||
USER_SETUP_VER_FILE="$HOME/.bluefin-vscode-configured" | ||
USER_SETUP_VER_RAN=$(cat "$USER_SETUP_VER_FILE") | ||
|
||
# Run script if updated | ||
if [[ -f $USER_SETUP_VER_FILE && "$USER_SETUP_VER" = "$USER_SETUP_VER_RAN" ]]; then | ||
echo "User setup has already run. Exiting..." | ||
exit 0 | ||
fi | ||
|
||
# Setup VSCode | ||
# Pre-install preferred VSCode Extensions | ||
code --install-extension ms-vscode-remote.remote-containers | ||
code --install-extension ms-azuretools.vscode-docker | ||
|
||
# Prevent future executions | ||
echo "Writing state file" | ||
echo "$USER_SETUP_VER" > "$USER_SETUP_VER_FILE" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
[Unit] | ||
Description=Run | ||
Wants=network-online.target | ||
After=network-online.target ublue-user-setup.service | ||
|
||
[Service] | ||
Type=oneshot | ||
ExecStart=/usr/bin/bluefin-dx-vscode | ||
Restart=on-failure | ||
RestartSec=30 | ||
StartLimitInterval=0 | ||
|
||
[Install] | ||
WantedBy=default.target |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters