mirror of
https://git.freebsd.org/ports.git
synced 2025-06-29 16:40:31 -04:00
Changelog: - https://github.com/electron/electron/releases/tag/v22.0.2 - https://github.com/electron/electron/releases/tag/v22.0.3 - https://github.com/electron/electron/releases/tag/v22.1.0 PR: 269194 Reported by: Yonas Yanfa <yonas.yanfa@gmail.com> Approved by: mikael (maintainer)
17 lines
978 B
JavaScript
17 lines
978 B
JavaScript
--- electron/script/lib/get-version.js.orig 2023-01-24 16:58:16 UTC
|
|
+++ electron/script/lib/get-version.js
|
|
@@ -11,12 +11,10 @@ module.exports.getElectronVersion = () => {
|
|
// The only difference in the "git describe" technique is that technically a commit can "change" it's version
|
|
// number if a tag is created / removed retroactively. i.e. the first time a commit is pushed it will be 1.2.3
|
|
// and after the tag is made rebuilding the same commit will result in it being 1.2.4
|
|
- const output = spawnSync('git', ['describe', '--tags', '--abbrev=0'], {
|
|
- cwd: path.resolve(__dirname, '..', '..')
|
|
- });
|
|
+ const output = spawnSync('basename', [path.resolve(__dirname, '..', '..', '..', '..')]);
|
|
if (output.status !== 0) {
|
|
console.error(output.stderr);
|
|
throw new Error('Failed to get current electron version');
|
|
}
|
|
- return output.stdout.toString().trim().replace(/^v/g, '');
|
|
+ return output.stdout.toString().trim().replace(/^electron-/g, '');
|
|
};
|