Skip to content

Commit

Permalink
Add linux/ppc64le and linux/s390x binaries
Browse files Browse the repository at this point in the history
  • Loading branch information
yselkowitz committed Jan 26, 2023
1 parent 9ecddb6 commit 6e38283
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 1 deletion.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ ls-lint-darwin
ls-lint-darwin-arm64
ls-lint-linux
ls-lint-linux-arm64
ls-lint-linux-ppc64le
ls-lint-linux-s390x
ls-lint-windows.exe
/coverage.txt
!npm
14 changes: 13 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ build:
GOOS=darwin GOARCH=arm64 go build -o ls-lint-darwin-arm64
GOOS=linux GOARCH=amd64 go build -o ls-lint-linux
GOOS=linux GOARCH=arm64 go build -o ls-lint-linux-arm64
GOOS=linux GOARCH=ppc64le go build -o ls-lint-linux-ppc64le
GOOS=linux GOARCH=s390x go build -o ls-lint-linux-s390x
GOOS=windows GOARCH=amd64 go build -o ls-lint-windows.exe

build-npm:
Expand All @@ -20,6 +22,8 @@ build-npm:
make build-npm-darwin-arm64
make build-npm-linux
make build-npm-linux-arm64
make build-npm-linux-ppc64le
make build-npm-linux-s390x
make build-npm-windows

build-npm-darwin:
Expand All @@ -38,6 +42,14 @@ build-npm-linux-arm64:
cp ls-lint-linux-arm64 npm/bin/ls-lint-linux-arm64
chmod +x npm/bin/ls-lint-linux-arm64

build-npm-linux-ppc64le:
cp ls-lint-linux-ppc64le npm/bin/ls-lint-linux-ppc64le
chmod +x npm/bin/ls-lint-linux-ppc64le

build-npm-linux-s390x:
cp ls-lint-linux-s390x npm/bin/ls-lint-linux-s390x
chmod +x npm/bin/ls-lint-linux-s390x

build-npm-windows:
cp ls-lint-windows.exe npm/bin/ls-lint-windows.exe
chmod +x npm/bin/ls-lint-windows.exe
Expand All @@ -46,4 +58,4 @@ docker-build:
docker build -f docker/Dockerfile -t ls-lint-dev:latest .

docker-run:
docker run --rm -v ${PWD}:/data ls-lint-dev:latest
docker run --rm -v ${PWD}:/data ls-lint-dev:latest
4 changes: 4 additions & 0 deletions npm/bin/cli.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ function getPlatformPath() {
return 'ls-lint-linux';
case 'arm64':
return 'ls-lint-linux-arm64';
case 'ppc64le':
return 'ls-lint-linux-ppc64le';
case 's390x':
return 'ls-lint-linux-s390x';
default:
console.log('ls-lint builds are not available on platform: ' + process.platform + ' arch: ' + process.arch);
process.exit(1);
Expand Down
2 changes: 2 additions & 0 deletions npm/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
"cpu": [
"x64",
"arm64"
"ppc64le"
"s390x"
],
"keywords": [
"linter",
Expand Down

0 comments on commit 6e38283

Please sign in to comment.