build: convert all release scripts to typescript (#44059)

* build: convert all release scripts to typescript (#44035)

* build: convert all release scripts to typescript

* fix test imports

* build: fix version bumper export

* refactor: use as const

* spec: fix bad type spec

* build: use ts-node to spawn the version-bumper (#44057)

Missed this in the tsification, we should probably call this via API instead of spawning a sub-proc?

* build: still colors
This commit is contained in:
Samuel Attard 2024-10-01 03:04:22 -07:00 committed by GitHub
parent 52a8d133cd
commit fc9cda72d2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
22 changed files with 1164 additions and 772 deletions

View file

@ -385,12 +385,12 @@ def upload_sha256_checksum(version, file_path, key_prefix=None):
def get_release(version):
script_path = os.path.join(
ELECTRON_DIR, 'script', 'release', 'find-github-release.js')
ELECTRON_DIR, 'script', 'release', 'find-github-release.ts')
# Strip warnings from stdout to ensure the only output is the desired object
release_env = os.environ.copy()
release_env['NODE_NO_WARNINGS'] = '1'
release_info = execute(['node', script_path, version], release_env)
release_info = execute([TS_NODE, script_path, version], release_env)
if is_verbose_mode():
print(f'Release info for version: {version}:\n')
print(release_info)