Skip to content

Commit 870ca0c

Browse files
author
Codesphere Developer
committed
fix(ci): fix syntax error in prepare_vscode.sh patch
This commit modifies ci-branding.sh to insert a 'true' no-op command into prepare_vscode.sh's windows block, preventing a syntax error caused by an empty if/elif block.
1 parent 02f59a4 commit 870ca0c

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

ci/ci-branding.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,8 +60,11 @@ if [ -f "$VSCODIUM_DIR/prepare_vscode.sh" ]; then
6060
perl -pi -e 's/setpath "product" "(nameShort|nameLong|applicationName|linuxIconName|urlProtocol|serverApplicationName|serverDataFolderName|darwinBundleIdentifier|win32AppUserModelId|win32DirName|win32MutexName|win32NameVersion|win32RegValueName|win32ShellNameShort)" ".*"/# branding parameter suppressed by Codesphere patch/' "$VSCODIUM_DIR/prepare_vscode.sh"
6161

6262
# Prevent prepare_vscode.sh from messing with code.iss (we handle it in enforce-branding.sh)
63+
# Prevent prepare_vscode.sh from messing with code.iss (we handle it in enforce-branding.sh)
64+
# IMPORTANT: We replace the command with "true" (no-op) to ensure the if/elif block isn't left empty,
65+
# which would cause a "syntax error near unexpected token fi"
6366
echo "🔧 Patching prepare_vscode.sh to leave code.iss alone..."
64-
perl -pi -e 's/sed -i .s\|Microsoft Corporation\|VSCodium\|. build\/win32\/code.iss/# code.iss modification suppressed/' "$VSCODIUM_DIR/prepare_vscode.sh"
67+
perl -pi -e 's/sed -i .s\|Microsoft Corporation\|VSCodium\|. build\/win32\/code.iss/true; # code.iss modification suppressed/' "$VSCODIUM_DIR/prepare_vscode.sh"
6568
perl -pi -e 's/sed -i .s\|https:\/\/code.visualstudio.com\|https:\/\/vscodium.com\|. build\/win32\/code.iss/# code.iss modification suppressed/' "$VSCODIUM_DIR/prepare_vscode.sh"
6669

6770
# Ensure the product.json merge at the end doesn't overwrite our product.json if we want to be safe,

0 commit comments

Comments
 (0)