tools: move python code out of jenkins shell
https://ci.nodejs.org/job/node-test-commit-v8-linux/configure echoes python code into tools and runs it. Move these scripts into tools for better maintainability. Once this lands and is back-ported into LTS branches a bunch of shell code can be deleted from the job. PR-URL: https://github.com/nodejs/node/pull/28458 Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: Michael Dawson <michael_dawson@ca.ibm.com> Reviewed-By: Rich Trott <rtrott@gmail.com>
This commit is contained in:
parent
e669b8154c
commit
ed14aa6d51
10
tools/getarch.py
Normal file
10
tools/getarch.py
Normal file
@ -0,0 +1,10 @@
|
||||
from __future__ import print_function
|
||||
from utils import GuessArchitecture
|
||||
arch = GuessArchitecture()
|
||||
|
||||
# assume 64 bit unless set specifically
|
||||
print(GuessArchitecture() \
|
||||
.replace('ia32', 'x64') \
|
||||
.replace('ppc', 'ppc64') \
|
||||
.replace('arm', 'arm64') \
|
||||
.replace('s390', 's390x'))
|
4
tools/getendian.py
Normal file
4
tools/getendian.py
Normal file
@ -0,0 +1,4 @@
|
||||
from __future__ import print_function
|
||||
import sys
|
||||
# "little" or "big"
|
||||
print(sys.byteorder)
|
3
tools/getmachine.py
Normal file
3
tools/getmachine.py
Normal file
@ -0,0 +1,3 @@
|
||||
from __future__ import print_function
|
||||
import platform
|
||||
print(platform.machine())
|
@ -1,3 +1,4 @@
|
||||
from __future__ import print_function
|
||||
import os
|
||||
import re
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user