Skip to content

Commit 8d815a5

Browse files
committed
[Modules] Adding cpptools vscode extension
1 parent c00d171 commit 8d815a5

1 file changed

Lines changed: 23 additions & 0 deletions

File tree

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
#!/bin/bash
2+
3+
EXTENSION_NAME="vsc-cpptools"
4+
EXTENSION_FILE="$EXTENSION_NAME.vsix"
5+
EXTENSION_URL="https://github.com/microsoft/vscode-cpptools/releases/download/v1.16.3/cpptools-linux.vsix"
6+
EXTENSION_FOLDER="$EXTENSION_NAME/extension"
7+
# Downloads extension
8+
curl -o "$EXTENSION_NAME.vsix" -L "$EXTENSION_URL"
9+
# Extracts current extension
10+
mkdir "$EXTENSION_NAME"
11+
unzip -q "$EXTENSION_FILE" -d "$EXTENSION_NAME"
12+
13+
LAB_FOLDER="$EXTENSION_NAME-hsm-lab/"
14+
DESTINATION_FOLDER="$LAB_FOLDER/usr/share/codium/resources/app/extensions"
15+
16+
# Moves extension to the destination folder
17+
mkdir -p "$DESTINATION_FOLDER"
18+
mv "$EXTENSION_FOLDER" "$DESTINATION_FOLDER/$EXTENSION_NAME"
19+
mksquashfs "$LAB_FOLDER" "$EXTENSION_NAME.hsm" -quiet
20+
rm -r "$LAB_FOLDER" "$EXTENSION_FILE" "$EXTENSION_NAME"
21+
22+
# Moves the output file
23+
mv "$EXTENSION_NAME.hsm" /run/initramfs/memory/system/huronOS/software/programming/

0 commit comments

Comments
 (0)