Skip to content

Commit

Permalink
feat: imporvments for github CI
Browse files Browse the repository at this point in the history
  • Loading branch information
KotRikD committed Dec 20, 2023
1 parent 78033e9 commit a30e35b
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 19 deletions.
52 changes: 33 additions & 19 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
pull_request:
branches:
- '*'
workflow_dispatch:

concurrency:
group: build-${{ github.ref_name }}
Expand All @@ -17,7 +18,37 @@ concurrency:
permissions:
contents: write

flow-prepare-jobs: &flow-prepare-jobs
- name: Checkout 🛎️
uses: actions/checkout@v3

- name: Install Node.js 🔧
uses: actions/setup-node@v3
with:
node-version: 18

- name: Install Rust 🔧
uses: ATiltedTree/setup-rust@v1
with:
rust-version: stable
components: clippy

- name: Install Deps 🔧
run: |
npm install -g pnpm@^8
pnpm install --frozen-lockfile
jobs:
lint:
runs-on: "windows-latest"
name: "Lint project"
steps:
<<: *flow-prepare-jobs

- name: Lint project
run: |
pnpm run prettier:ci
build:
strategy:
matrix:
Expand All @@ -27,24 +58,7 @@ jobs:
runs-on: "${{ matrix.os }}"
name: "Build on ${{ matrix.os }}"
steps:
- name: Checkout 🛎️
uses: actions/checkout@v3

- name: Install Node.js 🔧
uses: actions/setup-node@v3
with:
node-version: 18

- name: Install Rust 🔧
uses: ATiltedTree/setup-rust@v1
with:
rust-version: stable
components: clippy

- name: Install Deps 🔧
run: |
npm install -g pnpm@^8
pnpm install --frozen-lockfile
<<: *flow-prepare-jobs

- name: Build App 🔧
run: |
Expand All @@ -68,5 +82,5 @@ jobs:
if: startsWith( matrix.os, 'windows' )
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.os }}-${{ github.ref_name }}
name: ${{ matrix.os }}
path: packages/tosu/dist/tosu.exe
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"prepare": "husky install",
"start": "pnpm run -C packages/tosu run:dev",
"build": "pnpm run -C packages/tosu compile",
"prettier:ci": "prettier --check \"**/*.{js,jsx,ts,tsx,css,scss}\"",
"prettier:fix": "prettier --write \"**/*.{js,jsx,ts,tsx,css,scss}\""
},
"dependencies": {
Expand Down

0 comments on commit a30e35b

Please sign in to comment.