mirror of
https://github.com/jackyzha0/quartz.git
synced 2026-03-24 23:15:46 -05:00
rem unused action, moved it to the dotfiles repo
This commit is contained in:
parent
43a53db30c
commit
3df9bea6e2
86
.github/actions/pnpm-install/action.yml
vendored
86
.github/actions/pnpm-install/action.yml
vendored
@ -1,86 +0,0 @@
|
|||||||
########################################################################################
|
|
||||||
# "pnpm install" composite action for pnpm 7/8+ #
|
|
||||||
#--------------------------------------------------------------------------------------#
|
|
||||||
# Requirement: @setup/node should be run before #
|
|
||||||
# #
|
|
||||||
# Usage in workflows steps: #
|
|
||||||
# #
|
|
||||||
# - name: 📥 Monorepo install #
|
|
||||||
# uses: ./.github/actions/pnpm-install #
|
|
||||||
# with: #
|
|
||||||
# enable-corepack: false # (default) #
|
|
||||||
# cwd: ${{ github.workspace }}/apps/my-app # (default = '.') #
|
|
||||||
# #
|
|
||||||
# Reference: #
|
|
||||||
# - latest: https://gist.github.com/belgattitude/838b2eba30c324f1f0033a797bab2e31 #
|
|
||||||
# #
|
|
||||||
# Versions: #
|
|
||||||
# - 1.1.0 - 15-07-2023 - Add project custom directory support. #
|
|
||||||
########################################################################################
|
|
||||||
|
|
||||||
name: "PNPM install"
|
|
||||||
description: "Run pnpm install with cache enabled"
|
|
||||||
|
|
||||||
inputs:
|
|
||||||
enable-corepack:
|
|
||||||
description: "Enable corepack"
|
|
||||||
required: false
|
|
||||||
default: "false"
|
|
||||||
cwd:
|
|
||||||
description: "Changes node's process.cwd() if the project is not located on the root. Default to process.cwd()"
|
|
||||||
required: false
|
|
||||||
default: "."
|
|
||||||
|
|
||||||
runs:
|
|
||||||
using: "composite"
|
|
||||||
|
|
||||||
steps:
|
|
||||||
- name: ⚙️ Enable Corepack
|
|
||||||
if: ${{ inputs.enable-corepack == 'true' }}
|
|
||||||
shell: bash
|
|
||||||
working-directory: ${{ inputs.cwd }}
|
|
||||||
run: |
|
|
||||||
corepack enable
|
|
||||||
echo "corepack enabled"
|
|
||||||
|
|
||||||
- uses: pnpm/action-setup@v2.2.4
|
|
||||||
if: ${{ inputs.enable-corepack == 'false' }}
|
|
||||||
with:
|
|
||||||
run_install: false
|
|
||||||
# If you're not setting the packageManager field in package.json, add the version here
|
|
||||||
# version: 8.6.7
|
|
||||||
|
|
||||||
- name: Expose pnpm config(s) through "$GITHUB_OUTPUT"
|
|
||||||
id: pnpm-config
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
- name: Cache rotation keys
|
|
||||||
id: cache-rotation
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
echo "YEAR_MONTH=$(/bin/date -u "+%Y%m")" >> $GITHUB_OUTPUT
|
|
||||||
|
|
||||||
- uses: actions/cache@v3
|
|
||||||
name: Setup pnpm cache
|
|
||||||
with:
|
|
||||||
path: ${{ steps.pnpm-config.outputs.STORE_PATH }}
|
|
||||||
key: ${{ runner.os }}-pnpm-store-cache-${{ steps.cache-rotation.outputs.YEAR_MONTH }}-${{ hashFiles('**/pnpm-lock.yaml') }}
|
|
||||||
restore-keys: |
|
|
||||||
${{ runner.os }}-pnpm-store-cache-${{ steps.cache-rotation.outputs.YEAR_MONTH }}-
|
|
||||||
|
|
||||||
# Prevent store to grow over time (not needed with yarn)
|
|
||||||
# Note: not perfect as it prune too much in monorepos so the idea
|
|
||||||
# is to use cache-rotation as above. In the future this might work better.
|
|
||||||
#- name: Prune pnpm store
|
|
||||||
# shell: bash
|
|
||||||
# run: pnpm prune store
|
|
||||||
|
|
||||||
- name: Install dependencies
|
|
||||||
shell: bash
|
|
||||||
working-directory: ${{ inputs.cwd }}
|
|
||||||
run: pnpm install --frozen-lockfile --prefer-offline
|
|
||||||
env:
|
|
||||||
# Other environment variables
|
|
||||||
HUSKY: "0" # By default do not run HUSKY install
|
|
||||||
6
.github/workflows/build.yml
vendored
6
.github/workflows/build.yml
vendored
@ -1,4 +1,4 @@
|
|||||||
name: Build only
|
name: Quartz - Build only
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
@ -25,8 +25,8 @@ jobs:
|
|||||||
fetch-depth: 0 # Fetch all history for git info
|
fetch-depth: 0 # Fetch all history for git info
|
||||||
- uses: actions/setup-node@v4
|
- uses: actions/setup-node@v4
|
||||||
with:
|
with:
|
||||||
node-version: 20.11.0 # 18
|
node-version: 18
|
||||||
- name: Install Dependencies
|
- name: Install Dependencies
|
||||||
run: npm i # was npm ci
|
run: npm i
|
||||||
- name: Build Quartz
|
- name: Build Quartz
|
||||||
run: npx quartz build
|
run: npx quartz build
|
||||||
|
|||||||
2
.github/workflows/ci.yaml
vendored
2
.github/workflows/ci.yaml
vendored
@ -1,4 +1,4 @@
|
|||||||
name: Build and Test
|
name: Quartz - CI Test
|
||||||
|
|
||||||
on:
|
on:
|
||||||
pull_request:
|
pull_request:
|
||||||
|
|||||||
2
.github/workflows/deploy.yml
vendored
2
.github/workflows/deploy.yml
vendored
@ -1,4 +1,4 @@
|
|||||||
name: Deploy to GitHub Pages
|
name: Quartz - Deploy to GitHub Pages
|
||||||
|
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user