parent
bc579fa55e
commit
1a51948f9c
|
@ -230,12 +230,14 @@ function packageTask(platform, arch, opts) {
|
|||
.pipe(filter(['**', '!LICENSE', '!LICENSES.chromium.html', '!version']));
|
||||
|
||||
if (platform === 'win32') {
|
||||
var shortcutFilter = filter('bin/*.cmd', { restore: true });
|
||||
result = es.merge(result, gulp.src('sources/win32/bin/code.js', { base: 'resources/win32' }));
|
||||
|
||||
result = es.merge(result, gulp.src('resources/win32/bin/**', { base: 'resources/win32' }))
|
||||
.pipe(shortcutFilter)
|
||||
.pipe(rename(function (f) { f.basename = product.applicationName; }))
|
||||
.pipe(shortcutFilter.restore);
|
||||
result = es.merge(result, gulp.src('sources/win32/bin/code.cmd', { base: 'resources/win32' })
|
||||
.pipe(rename(function (f) { f.basename = product.applicationName; })));
|
||||
|
||||
result = es.merge(result, gulp.src('sources/win32/bin/code.sh', { base: 'resources/win32' })
|
||||
.pipe(replace('@@NAME@@', product.nameShort))
|
||||
.pipe(rename(function (f) { f.basename = product.applicationName; f.extname = ''; })));
|
||||
}
|
||||
|
||||
return result.pipe(symdest(destination));
|
||||
|
|
11
resources/win32/bin/code.sh
Normal file
11
resources/win32/bin/code.sh
Normal file
|
@ -0,0 +1,11 @@
|
|||
#!/usr/bin/env bash
|
||||
#
|
||||
# Copyright (c) Microsoft Corporation. All rights reserved.
|
||||
# Licensed under the MIT License. See License.txt in the project root for license information.
|
||||
|
||||
NAME="@@NAME@@"
|
||||
VSCODE_PATH="$(dirname "$(dirname "$(realpath "$0")")")"
|
||||
ELECTRON="$VSCODE_PATH/$NAME.exe"
|
||||
CLI="$VSCODE_PATH/resources/app/out/cli.js"
|
||||
ELECTRON_NO_ATTACH_CONSOLE=1 ATOM_SHELL_INTERNAL_RUN_AS_NODE=1 "$ELECTRON" "$CLI" "$@"
|
||||
exit $?
|
Loading…
Reference in a new issue