Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
zhengyangliu committed Jun 30, 2024
2 parents 9b3845d + c108fde commit 5ff8b8a
Show file tree
Hide file tree
Showing 6 changed files with 30,367 additions and 9,511 deletions.
46 changes: 40 additions & 6 deletions .github/workflows/build-and-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ on:

jobs:
create-release:
runs-on: ubuntu-20.04
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

Expand Down Expand Up @@ -55,7 +55,7 @@ jobs:
draft: true
prerelease: false

build-windows:
build-windows-x64:
needs: create-release
runs-on: windows-2019
steps:
Expand All @@ -64,10 +64,11 @@ jobs:
- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: '16.x'
node-version: '14.x'

- name: Npm Install
run: |
git config --global url."https://github.com".insteadOf ssh://[email protected]
npm ci
- name: Build and Publish
Expand All @@ -78,6 +79,31 @@ jobs:
NODE_OPTIONS: --max_old_space_size=4096
run: npm run publish

build-windows-ia32:
needs: create-release
runs-on: windows-2019
steps:
- uses: actions/checkout@v2

- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: '14.x'

- name: Npm Install
run: |
git config --global url."https://github.com".insteadOf ssh://[email protected]
npm ci
- name: Build and Publish
env:
GA_ID: ${{ secrets.GA_ID }}
GH_TOKEN: ${{ secrets.GH_TOKEN }}
NODE_ENV: production
NODE_OPTIONS: --max_old_space_size=4096
ARCH: ia32
run: npm run publish

build-mac:
needs: create-release
runs-on: macos-13
Expand All @@ -89,9 +115,14 @@ jobs:
with:
node-version: '16.x'

- name: Install python2.7
run: |
brew install pyenv
pyenv install 2.7.18
pyenv global 2.7.18
- name: Npm Install
run: |
pip install setuptools
npm ci
- name: Build and Publish
Expand All @@ -101,9 +132,12 @@ jobs:
NODE_ENV: production
NODE_OPTIONS: --max_old_space_size=8192
CSC_IDENTITY_AUTO_DISCOVERY: false
run: npm run publish
PYTHON_PATH: python
run: |
export PYTHON_PATH=$(pyenv root)/shims/python
npm run publish
build-linux:
build-linux-amd64:
needs: create-release
runs-on: ubuntu-20.04
steps:
Expand Down
53 changes: 46 additions & 7 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,31 +10,62 @@ on:
- '.github/*'

jobs:
build-windows:
build-windows-x64:
runs-on: windows-2019
steps:
- uses: actions/checkout@v2

- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: '16.x'
node-version: '14.x'

- name: Npm Install
run: |
git config --global url."https://github.com".insteadOf ssh://[email protected]
npm ci
- name: Build Dist
env:
GA_ID: ${{ secrets.GA_ID }}
NODE_ENV: production
NODE_OPTIONS: --max_old_space_size=4096
run: npm run dist

- name: Archive production artifacts
uses: actions/upload-artifact@v2
with:
name: OpenBlock-Desktop-win-x64
path: dist/OpenBlock-Desktop*.exe
retention-days: 1

build-windows-ia32:
runs-on: windows-2019
steps:
- uses: actions/checkout@v2

- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: '14.x'

- name: Npm Install
run: |
git config --global url."https://github.com".insteadOf ssh://[email protected]
npm ci
- name: Build Dist
env:
GA_ID: ${{ secrets.GA_ID }}
NODE_ENV: production
NODE_OPTIONS: --max_old_space_size=4096
ARCH: ia32
run: npm run dist

- name: Archive production artifacts
uses: actions/upload-artifact@v2
with:
name: OpenBlock-Desktop-win32
name: OpenBlock-Desktop-win-ia32
path: dist/OpenBlock-Desktop*.exe
retention-days: 1

Expand All @@ -48,6 +79,12 @@ jobs:
with:
node-version: '16.x'

- name: Install python2.7
run: |
brew install pyenv
pyenv install 2.7.18
pyenv global 2.7.18
- name: Npm Install
run: |
pip install setuptools
Expand All @@ -59,16 +96,18 @@ jobs:
NODE_ENV: production
NODE_OPTIONS: --max_old_space_size=8192
CSC_IDENTITY_AUTO_DISCOVERY: false
run: npm run dist
run: |
export PYTHON_PATH=$(pyenv root)/shims/python
npm run dist
- name: Archive production artifacts
uses: actions/upload-artifact@v2
with:
name: OpenBlock-Desktop-darwin
name: OpenBlock-Desktop-mac-x64
path: dist/OpenBlock-Desktop*.dmg
retention-days: 1

build-linux:
build-linux-amd64:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
Expand All @@ -92,6 +131,6 @@ jobs:
- name: Archive production artifacts
uses: actions/upload-artifact@v2
with:
name: OpenBlock-Desktop-linux
name: OpenBlock-Desktop-linux-amd64
path: dist/OpenBlock-Desktop*.deb
retention-days: 1
Loading

0 comments on commit 5ff8b8a

Please sign in to comment.