Moved CI to pnpm and added lockfile update chore
This commit is contained in:
parent
e612622054
commit
96a4c759cc
2 changed files with 44 additions and 16 deletions
|
@ -20,30 +20,29 @@ jobs:
|
||||||
command: |
|
command: |
|
||||||
sudo apt-get update -y
|
sudo apt-get update -y
|
||||||
sudo apt-get install -y autoconf automake g++ libtool || true
|
sudo apt-get install -y autoconf automake g++ libtool || true
|
||||||
|
curl -f https://get.pnpm.io/v6.16.js | node - add --global pnpm@7
|
||||||
|
pnpm config set store-dir ~/.pnpm-store
|
||||||
- run:
|
- run:
|
||||||
name: Update Version Number of App
|
name: Fetch Application Version
|
||||||
command: sudo chmod +x resources/version.sh && ./resources/version.sh || true
|
command: sudo chmod +x resources/version.sh && ./resources/version.sh || true
|
||||||
- restore_cache:
|
- restore_cache:
|
||||||
name: Restore Yarn Package Cache
|
name: Restore cached node-modules
|
||||||
keys:
|
keys:
|
||||||
- yarn-packages-{{ checksum "cider.lock" }}
|
- node-{{ checksum "pnpm-lock.yaml" }}
|
||||||
- run:
|
- run:
|
||||||
name: Clear node_airtunes2 cache
|
name: Clear node_airtunes2 cache
|
||||||
command: sudo rm -rf ~/.cache/yarn/v6/.tmp/cf5bc2de2629636ca224995234b8eaa1 || true
|
command: sudo rm -rf ~/.pnpm-store/tmp/cf5bc2de2629636ca224995234b8eaa1 || true
|
||||||
- run:
|
- run:
|
||||||
name: Install Node Dependencies
|
name: Install Node Dependencies
|
||||||
command: yarn install --frozen-lockfile --cache-folder ~/.cache/yarn
|
command: pnpm install
|
||||||
- save_cache:
|
- save_cache:
|
||||||
name: Save Yarn Package Cache
|
name: Cache node-modules
|
||||||
key: yarn-packages-{{ checksum "cider.lock" }}
|
key: node-{{ checksum "pnpm-lock.yaml" }}
|
||||||
paths:
|
paths:
|
||||||
- ~/.cache/yarn
|
- ~/.pnpm-store
|
||||||
- run:
|
|
||||||
name: Clear Yarn Cache
|
|
||||||
command: yarn cache clean
|
|
||||||
- run:
|
- run:
|
||||||
name: TypeScript Compile
|
name: TypeScript Compile
|
||||||
command: yarn build
|
command: pnpm run build
|
||||||
- persist_to_workspace:
|
- persist_to_workspace:
|
||||||
# Must be an absolute path, or relative path from working_directory. This is a directory on the container which is
|
# Must be an absolute path, or relative path from working_directory. This is a directory on the container which is
|
||||||
# taken to be the root directory of the workspace.
|
# taken to be the root directory of the workspace.
|
||||||
|
@ -54,7 +53,6 @@ jobs:
|
||||||
- node_modules
|
- node_modules
|
||||||
- build
|
- build
|
||||||
- resources
|
- resources
|
||||||
- yarn.lock
|
|
||||||
- package.json
|
- package.json
|
||||||
- winget.json # winget.json is a file that is generated by the winget package manager
|
- winget.json # winget.json is a file that is generated by the winget package manager
|
||||||
- LICENSE
|
- LICENSE
|
||||||
|
@ -66,7 +64,7 @@ jobs:
|
||||||
at: ~/Cider
|
at: ~/Cider
|
||||||
- run:
|
- run:
|
||||||
name: Generate Builds (Linux)
|
name: Generate Builds (Linux)
|
||||||
command: yarn electron-builder -l -p never
|
command: npm run electron-builder -l -p never
|
||||||
post-steps:
|
post-steps:
|
||||||
- jira/notify
|
- jira/notify
|
||||||
- persist_to_workspace:
|
- persist_to_workspace:
|
||||||
|
@ -85,7 +83,7 @@ jobs:
|
||||||
at: ~/project
|
at: ~/project
|
||||||
- run:
|
- run:
|
||||||
name: Generate Builds (Windows)
|
name: Generate Builds (Windows)
|
||||||
command: yarn electron-builder -w --x64 -p never
|
command: npm run electron-builder -w --x64 -p never
|
||||||
post-steps:
|
post-steps:
|
||||||
- jira/notify
|
- jira/notify
|
||||||
- persist_to_workspace:
|
- persist_to_workspace:
|
||||||
|
@ -103,7 +101,7 @@ jobs:
|
||||||
at: ~/project
|
at: ~/project
|
||||||
- run:
|
- run:
|
||||||
name: Generate Builds (Winget)
|
name: Generate Builds (Winget)
|
||||||
command: yarn electron-builder --win -c winget.json -p never
|
command: npm run electron-builder --win -c winget.json -p never
|
||||||
post-steps:
|
post-steps:
|
||||||
- jira/notify
|
- jira/notify
|
||||||
- persist_to_workspace:
|
- persist_to_workspace:
|
||||||
|
|
30
.github/workflows/lockfile.yml
vendored
Normal file
30
.github/workflows/lockfile.yml
vendored
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
name: Continuous Integration (Lockfile)
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
prettier:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
permissions:
|
||||||
|
contents: write
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Checkout
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
# Make sure the actual branch is checked out when running on pull requests
|
||||||
|
ref: ${{ github.head_ref }}
|
||||||
|
|
||||||
|
- name: Update lockfile
|
||||||
|
run: pnpm i --lockfile-only
|
||||||
|
|
||||||
|
- name: Commit Updated Lockfile
|
||||||
|
uses: stefanzweifel/git-auto-commit-action@v4.14.1
|
||||||
|
with:
|
||||||
|
commit_message: "chore: Updated Lockfile\n [ci skip]"
|
||||||
|
commit_user_name: "cider-chore[bot]"
|
||||||
|
commit_user_email: "cider-chore[bot]@users.noreply.github.com"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue