Add steampipe files and upgrade electron
This commit is contained in:
parent
1c97f3f32a
commit
c4d709b8e4
|
@ -1,16 +1,16 @@
|
||||||
{
|
{
|
||||||
"name": "electron",
|
"name": "electron",
|
||||||
"version": "1.0.0",
|
"version": "1.0.0",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"private": true,
|
"private": true,
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"startDev": "electron --disable-direct-composition --in-process-gpu . --dev --local",
|
"startDev": "electron --disable-direct-composition --in-process-gpu . --dev --local",
|
||||||
"startDevGpu": "electron --enable-gpu-rasterization --enable-accelerated-2d-canvas --num-raster-threads=8 --enable-zero-copy . --dev --local",
|
"startDevGpu": "electron --enable-gpu-rasterization --enable-accelerated-2d-canvas --num-raster-threads=8 --enable-zero-copy . --dev --local",
|
||||||
"start": "electron --disable-direct-composition --in-process-gpu ."
|
"start": "electron --disable-direct-composition --in-process-gpu ."
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"electron": "^6.1.12"
|
"electron": "10.1.3"
|
||||||
},
|
},
|
||||||
"dependencies": {}
|
"dependencies": {}
|
||||||
}
|
}
|
||||||
|
|
1533
electron/yarn.lock
1533
electron/yarn.lock
File diff suppressed because it is too large
Load Diff
|
@ -1,2 +1 @@
|
||||||
additional_build_files
|
additional_build_files
|
||||||
steampipe
|
|
||||||
|
|
|
@ -1,9 +1,10 @@
|
||||||
require('colors');
|
require("colors");
|
||||||
const packager = require("electron-packager");
|
const packager = require("electron-packager");
|
||||||
const path = require("path");
|
const path = require("path");
|
||||||
const { getVersion } = require("./buildutils");
|
const { getVersion } = require("./buildutils");
|
||||||
const fs = require("fs");
|
const fs = require("fs");
|
||||||
const fse = require("fs-extra");
|
const fse = require("fs-extra");
|
||||||
|
const buildutils = require("./buildutils");
|
||||||
const execSync = require("child_process").execSync;
|
const execSync = require("child_process").execSync;
|
||||||
|
|
||||||
function gulptasksStandalone($, gulp) {
|
function gulptasksStandalone($, gulp) {
|
||||||
|
@ -47,6 +48,20 @@ function gulptasksStandalone($, gulp) {
|
||||||
cb();
|
cb();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
gulp.task("standalone.prepareVDF", cb => {
|
||||||
|
const hash = buildutils.getRevision();
|
||||||
|
|
||||||
|
const steampipeDir = path.join(__dirname, "steampipe", "scripts");
|
||||||
|
const templateContents = fs
|
||||||
|
.readFileSync(path.join(steampipeDir, "app.vdf.template"), { encoding: "utf-8" })
|
||||||
|
.toString();
|
||||||
|
|
||||||
|
const convertedContents = templateContents.replace("$DESC$", "Commit " + hash);
|
||||||
|
fs.writeFileSync(path.join(steampipeDir, "app.vdf"), convertedContents);
|
||||||
|
|
||||||
|
cb();
|
||||||
|
});
|
||||||
|
|
||||||
gulp.task("standalone.prepare.minifyCode", () => {
|
gulp.task("standalone.prepare.minifyCode", () => {
|
||||||
return gulp.src(path.join(electronBaseDir, "*.js")).pipe(gulp.dest(tempDestBuildDir));
|
return gulp.src(path.join(electronBaseDir, "*.js")).pipe(gulp.dest(tempDestBuildDir));
|
||||||
});
|
});
|
||||||
|
@ -101,20 +116,21 @@ function gulptasksStandalone($, gulp) {
|
||||||
overwrite: true,
|
overwrite: true,
|
||||||
appBundleId: "io.shapez.standalone",
|
appBundleId: "io.shapez.standalone",
|
||||||
appCategoryType: "public.app-category.games",
|
appCategoryType: "public.app-category.games",
|
||||||
...(isRelease && platform === "darwin" && {
|
...(isRelease &&
|
||||||
osxSign: {
|
platform === "darwin" && {
|
||||||
identity: process.env.SHAPEZ_CLI_APPLE_CERT_NAME,
|
osxSign: {
|
||||||
"hardened-runtime": true,
|
"identity": process.env.SHAPEZ_CLI_APPLE_CERT_NAME,
|
||||||
hardenedRuntime: true,
|
"hardened-runtime": true,
|
||||||
entitlements: 'entitlements.plist',
|
"hardenedRuntime": true,
|
||||||
'entitlements-inherit': 'entitlements.plist',
|
"entitlements": "entitlements.plist",
|
||||||
'signature-flags': 'library'
|
"entitlements-inherit": "entitlements.plist",
|
||||||
},
|
"signature-flags": "library",
|
||||||
osxNotarize: {
|
},
|
||||||
appleId: process.env.SHAPEZ_CLI_APPLE_ID,
|
osxNotarize: {
|
||||||
appleIdPassword: "@keychain:SHAPEZ_CLI_APPLE_ID"
|
appleId: process.env.SHAPEZ_CLI_APPLE_ID,
|
||||||
}
|
appleIdPassword: "@keychain:SHAPEZ_CLI_APPLE_ID",
|
||||||
})
|
},
|
||||||
|
}),
|
||||||
}).then(
|
}).then(
|
||||||
appPaths => {
|
appPaths => {
|
||||||
console.log("Packages created:", appPaths);
|
console.log("Packages created:", appPaths);
|
||||||
|
@ -140,9 +156,13 @@ function gulptasksStandalone($, gulp) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (process.platform === "win32" && platform === "darwin") {
|
if (process.platform === "win32" && platform === "darwin") {
|
||||||
console.warn("Cross-building for macOS on Windows: dereferencing symlinks.\n".red +
|
console.warn(
|
||||||
"This will nearly double app size and make code signature invalid. Sorry!\n".red.bold +
|
"Cross-building for macOS on Windows: dereferencing symlinks.\n".red +
|
||||||
"For more information, see " + "https://github.com/electron/electron-packager/issues/71".underline);
|
"This will nearly double app size and make code signature invalid. Sorry!\n"
|
||||||
|
.red.bold +
|
||||||
|
"For more information, see " +
|
||||||
|
"https://github.com/electron/electron-packager/issues/71".underline
|
||||||
|
);
|
||||||
|
|
||||||
// Clear up framework folders
|
// Clear up framework folders
|
||||||
fs.writeFileSync(
|
fs.writeFileSync(
|
||||||
|
@ -195,7 +215,9 @@ function gulptasksStandalone($, gulp) {
|
||||||
gulp.task("standalone.package.prod.linux64", cb => packageStandalone("linux", "x64", cb));
|
gulp.task("standalone.package.prod.linux64", cb => packageStandalone("linux", "x64", cb));
|
||||||
gulp.task("standalone.package.prod.linux32", cb => packageStandalone("linux", "ia32", cb));
|
gulp.task("standalone.package.prod.linux32", cb => packageStandalone("linux", "ia32", cb));
|
||||||
gulp.task("standalone.package.prod.darwin64", cb => packageStandalone("darwin", "x64", cb));
|
gulp.task("standalone.package.prod.darwin64", cb => packageStandalone("darwin", "x64", cb));
|
||||||
gulp.task("standalone.package.prod.darwin64.unsigned", cb => packageStandalone("darwin", "x64", cb, false));
|
gulp.task("standalone.package.prod.darwin64.unsigned", cb =>
|
||||||
|
packageStandalone("darwin", "x64", cb, false)
|
||||||
|
);
|
||||||
|
|
||||||
gulp.task(
|
gulp.task(
|
||||||
"standalone.package.prod",
|
"standalone.package.prod",
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
steamtemp
|
||||||
|
app.vdf
|
|
@ -0,0 +1,15 @@
|
||||||
|
"appbuild"
|
||||||
|
{
|
||||||
|
"appid" "1318690"
|
||||||
|
"desc" "$DESC$"
|
||||||
|
"buildoutput" "C:\work\shapez\shapez.io\gulp\steampipe\steamtemp"
|
||||||
|
"contentroot" ""
|
||||||
|
"setlive" ""
|
||||||
|
"preview" "0"
|
||||||
|
"local" ""
|
||||||
|
"depots"
|
||||||
|
{
|
||||||
|
"1318691" "C:\work\shapez\shapez.io\gulp\steampipe\scripts\windows.vdf"
|
||||||
|
"1318692" "C:\work\shapez\shapez.io\gulp\steampipe\scripts\linux.vdf"
|
||||||
|
}
|
||||||
|
}
|
|
@ -0,0 +1,12 @@
|
||||||
|
"DepotBuildConfig"
|
||||||
|
{
|
||||||
|
"DepotID" "1318692"
|
||||||
|
"contentroot" "C:\work\shapez\shapez.io\tmp_standalone_files\shapez.io-standalone-linux-x64"
|
||||||
|
"FileMapping"
|
||||||
|
{
|
||||||
|
"LocalPath" "*"
|
||||||
|
"DepotPath" "."
|
||||||
|
"recursive" "1"
|
||||||
|
}
|
||||||
|
"FileExclusion" "*.pdb"
|
||||||
|
}
|
|
@ -0,0 +1,12 @@
|
||||||
|
"DepotBuildConfig"
|
||||||
|
{
|
||||||
|
"DepotID" "1318691"
|
||||||
|
"contentroot" "C:\work\shapez\shapez.io\tmp_standalone_files\shapez.io-standalone-win32-x64"
|
||||||
|
"FileMapping"
|
||||||
|
{
|
||||||
|
"LocalPath" "*"
|
||||||
|
"DepotPath" "."
|
||||||
|
"recursive" "1"
|
||||||
|
}
|
||||||
|
"FileExclusion" "*.pdb"
|
||||||
|
}
|
|
@ -0,0 +1,4 @@
|
||||||
|
@echo off
|
||||||
|
cmd /c gulp standalone.prepareVDF
|
||||||
|
steamcmd +login %STEAM_UPLOAD_SHAPEZ_ID% %STEAM_UPLOAD_SHAPEZ_USER% +run_app_build %cd%/scripts/app.vdf +quit
|
||||||
|
start https://partner.steamgames.com/apps/builds/1318690
|
Reference in New Issue