From 13633eca2881850316670cbb2e4a40d6064ad301 Mon Sep 17 00:00:00 2001 From: Baptiste Augrain Date: Fri, 4 Apr 2025 14:26:53 +0200 Subject: [PATCH] feat: add default server template --- patches/add-remote-url.patch | 18 ++++++++++++++++++ patches/insider/add-remote-url.patch | 8 ++++---- 2 files changed, 22 insertions(+), 4 deletions(-) create mode 100644 patches/add-remote-url.patch diff --git a/patches/add-remote-url.patch b/patches/add-remote-url.patch new file mode 100644 index 0000000..e9176eb --- /dev/null +++ b/patches/add-remote-url.patch @@ -0,0 +1,18 @@ +diff --git a/build/gulpfile.reh.js b/build/gulpfile.reh.js +index c1d64c0..3e60e80 100644 +--- a/build/gulpfile.reh.js ++++ b/build/gulpfile.reh.js +@@ -321,3 +321,3 @@ function packageTask(type, platform, arch, sourceFolderName, destinationFolderNa + const productJsonStream = gulp.src(['product.json'], { base: '.' }) +- .pipe(json({ commit, date: readISODate('out-build'), version })) ++ .pipe(json({ commit, date: readISODate('out-build'), version, serverDownloadUrlTemplate: 'https://github.com/!!GH_REPO_PATH!!/releases/download/${version/!!APP_NAME_LC!!-reh-${os}-${arch}-${version}.tar.gz' })) + .pipe(es.through(function (file) { +diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js +index 7046ee0..9aa7bb0 100644 +--- a/build/gulpfile.vscode.js ++++ b/build/gulpfile.vscode.js +@@ -288,3 +288,3 @@ function packageTask(platform, arch, sourceFolderName, destinationFolderName, op + const productJsonStream = gulp.src(['product.json'], { base: '.' }) +- .pipe(json({ commit, date: readISODate('out-build'), checksums, version })) ++ .pipe(json({ commit, date: readISODate('out-build'), checksums, version, serverDownloadUrlTemplate: 'https://github.com/!!GH_REPO_PATH!!/releases/download/${version}/!!APP_NAME_LC!!-reh-${os}-${arch}-${version}.tar.gz' })) + .pipe(es.through(function (file) { diff --git a/patches/insider/add-remote-url.patch b/patches/insider/add-remote-url.patch index 00a152d..8a19157 100644 --- a/patches/insider/add-remote-url.patch +++ b/patches/insider/add-remote-url.patch @@ -1,18 +1,18 @@ diff --git a/build/gulpfile.reh.js b/build/gulpfile.reh.js -index c1d64c0..3e60e80 100644 +index 2606eed..3e60e80 100644 --- a/build/gulpfile.reh.js +++ b/build/gulpfile.reh.js @@ -321,3 +321,3 @@ function packageTask(type, platform, arch, sourceFolderName, destinationFolderNa const productJsonStream = gulp.src(['product.json'], { base: '.' }) -- .pipe(json({ commit, date: readISODate('out-build'), version })) +- .pipe(json({ commit, date: readISODate('out-build'), version, serverDownloadUrlTemplate: 'https://github.com/!!GH_REPO_PATH!!/releases/download/${version/!!APP_NAME_LC!!-reh-${os}-${arch}-${version}.tar.gz' })) + .pipe(json({ commit, date: readISODate('out-build'), version, serverDownloadUrlTemplate: 'https://github.com/!!GH_REPO_PATH!!-insiders/releases/download/${version}-insider/!!APP_NAME_LC!!-reh-${os}-${arch}-${version}-insider.tar.gz' })) .pipe(es.through(function (file) { diff --git a/build/gulpfile.vscode.js b/build/gulpfile.vscode.js -index 7046ee0..9aa7bb0 100644 +index b975c64..9aa7bb0 100644 --- a/build/gulpfile.vscode.js +++ b/build/gulpfile.vscode.js @@ -288,3 +288,3 @@ function packageTask(platform, arch, sourceFolderName, destinationFolderName, op const productJsonStream = gulp.src(['product.json'], { base: '.' }) -- .pipe(json({ commit, date: readISODate('out-build'), checksums, version })) +- .pipe(json({ commit, date: readISODate('out-build'), checksums, version, serverDownloadUrlTemplate: 'https://github.com/!!GH_REPO_PATH!!/releases/download/${version}/!!APP_NAME_LC!!-reh-${os}-${arch}-${version}.tar.gz' })) + .pipe(json({ commit, date: readISODate('out-build'), checksums, version, serverDownloadUrlTemplate: 'https://github.com/!!GH_REPO_PATH!!-insiders/releases/download/${version}-insider/!!APP_NAME_LC!!-reh-${os}-${arch}-${version}-insider.tar.gz' })) .pipe(es.through(function (file) {