Skip to content

Commit

Permalink
Final? build fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Inrixia committed May 1, 2024
1 parent 2384e28 commit 8e8e6e2
Show file tree
Hide file tree
Showing 4 changed files with 42 additions and 25 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/autoBuildDev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
with:
node-version: 21.x
- name: Install dependencies
run: npm install
run: npm ci
- name: Build
run: npm run build-${{ matrix.runs-on }}
- name: Upload Artifact
Expand Down
51 changes: 32 additions & 19 deletions .github/workflows/autoRelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,49 +7,62 @@ on:
- "master"

jobs:
GitHub:
name: "Release - GitHub"
runs-on: "ubuntu-latest"

Build:
strategy:
matrix:
runs-on: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.runs-on }}
steps:
- uses: actions/checkout@v4
- name: "Install dependencies"
run: |
npm install
- name: "Build"
run: |
npm run build
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: 21.x
- name: Install dependencies
run: npm ci
- name: Build
run: npm run build-${{ matrix.runs-on }}
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
name: build-${{ matrix.runs-on }}
path: ./build/

Release:
needs: Build
runs-on: ubuntu-latest
steps:
- name: Download All Artifacts
uses: actions/download-artifact@v4
with:
path: ./build/
merge-multiple: true
- name: Draft release on GitHub
uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: "latest"
draft: true
title: "Latest Release"
files: |
build/*
files: build/*

DockerHub:
name: "Release - DockerHub"
runs-on: "ubuntu-latest"

steps:
- name: Set up QEMU
uses: docker/setup-qemu-action@v2

uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
uses: docker/login-action@v1
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Build & Publish release on DockerHub
uses: docker/build-push-action@v2
uses: docker/build-push-action@v5
with:
push: true
tags: inrix/floatplane-downloader:latest
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/autoTest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,12 @@ jobs:

steps:
- uses: actions/checkout@v4
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: latest
- name: "Install dependencies"
run: npm install
run: npm ci
- name: "Compile & Sanity Test"
run: npm run test-esm

Expand All @@ -34,7 +38,7 @@ jobs:
with:
node-version: 21.x
- name: "Install dependencies"
run: npm install
run: npm ci
- name: "Build & Sanity Test"
run: npm run test-${{ matrix.runs-on }}

Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@
"sanity": "npm run checkLint && npm run test-esm && npm run test-windows",
"test-esm": "tsc && node ./dist/float.js --sanityCheck",
"test-ubuntu-latest": "npm run build-ubuntu-latest && ./build/float-linux --sanityCheck",
"test-windows-latest": "npm run build-windows-latest && cd ./build/float-win --sanityCheck",
"test-windows-latest": "npm run build-windows-latest && ./build/float-win.exe --sanityCheck",
"makeBlob": "node --experimental-sea-config ./sea-config.json",
"injectWin": "npx postject ./build/float-win.exe NODE_SEA_BLOB ./dist/float.blob --sentinel-fuse NODE_SEA_FUSE_fce680ab2cc467b6e072b8b5df1996b2 --overwrite",
"injectLinux": "npx postject ./build/float-linux NODE_SEA_BLOB ./dist/float.blob --sentinel-fuse NODE_SEA_FUSE_fce680ab2cc467b6e072b8b5df1996b2 --overwrite",
"injectWin": "npx postject ./build/float-win.exe NODE_SEA_BLOB ./dist/float.blob --sentinel-fuse NODE_SEA_FUSE_fce680ab2cc467b6e072b8b5df1996b2",
"injectLinux": "npx postject ./build/float-linux NODE_SEA_BLOB ./dist/float.blob --sentinel-fuse NODE_SEA_FUSE_fce680ab2cc467b6e072b8b5df1996b2",
"build-windows-latest": "node make.js ./build/float-win.exe && npm run bundle && npm run makeBlob && npm run injectWin",
"build-ubuntu-latest": "node make.js ./build/float-linux && npm run bundle && npm run makeBlob && npm run injectLinux"
},
Expand Down

0 comments on commit 8e8e6e2

Please sign in to comment.