Skip to content

Commit

Permalink
build: update infra (ikatyang#652)
Browse files Browse the repository at this point in the history
  • Loading branch information
ikatyang authored Jul 22, 2023
1 parent ef5ce59 commit 4896810
Show file tree
Hide file tree
Showing 23 changed files with 3,157 additions and 6,085 deletions.
1 change: 0 additions & 1 deletion .gitattributes

This file was deleted.

13 changes: 13 additions & 0 deletions .github/actions/setup/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: setup
description: setup
runs:
using: composite
steps:
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v3
with:
cache: pnpm
node-version: '18'
registry-url: 'https://registry.npmjs.org'
- run: pnpm install
shell: bash
24 changes: 0 additions & 24 deletions .github/workflows/lint.yml

This file was deleted.

39 changes: 21 additions & 18 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,27 @@
name: Test

on:
- push
- pull_request
push:
branches:
- master
pull_request:
branches:
- master

jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setup
- run: pnpm run lint
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setup
- run: pnpm run check
test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2

- name: Setup Node.js
uses: actions/setup-node@v2-beta
with:
node-version: "16"

- name: Install Dependencies
run: yarn

- name: Test
run: yarn test --ci
- uses: actions/checkout@v3
- uses: ./.github/actions/setup
- run: pnpm run test
20 changes: 4 additions & 16 deletions .github/workflows/update.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,28 +2,16 @@ name: Up to Date

on:
schedule:
- cron: "0 0 * * *"
- cron: '0 0 * * *'

jobs:
update:
name: Update
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Setup Node.js
uses: actions/setup-node@v2-beta
with:
node-version: "16"

- name: Install Dependencies
run: yarn

- name: Generate Cheat Sheet
run: yarn generate
- uses: actions/checkout@v3
- uses: ./.github/actions/setup
- run: pnpm run generate

- name: Push New Cheat Sheet to Updated Branch
run: |
Expand Down
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
node_modules/
/.vscode/
/node_modules/
2 changes: 2 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/pnpm-lock.yaml
/README.md
3 changes: 3 additions & 0 deletions .prettierrc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
arrowParens: avoid
semi: false
singleQuote: true
31 changes: 14 additions & 17 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"name": "emoji-cheat-sheet",
"type": "module",
"version": "0.0.0-dev",
"private": true,
"repository": "ikatyang/emoji-cheat-sheet",
Expand All @@ -11,25 +12,21 @@
},
"license": "MIT",
"scripts": {
"lint": "tslint -p . --type-check",
"test": "jest",
"generate": "node ./scripts/generate.js > ./README.md"
},
"dependencies": {
"request": "^2.88.0"
"lint": "prettier --check .",
"check": "tsc --noEmit",
"test": "vitest",
"generate": "vite-node ./scripts/generate.ts -- run > ./README.md"
},
"devDependencies": {
"@types/jest": "24.0.18",
"@types/node": "12.7.4",
"@types/request": "2.48.2",
"jest": "24.9.0",
"jest-playback": "2.0.2",
"prettier": "1.17.0",
"tslint": "5.19.0",
"tslint-plugin-prettier": "2.0.1",
"typescript": "3.6.2"
"jest-playback": "4.0.0",
"prettier": "3.0.0",
"typescript": "5.1.6",
"vite": "4.4.6",
"vite-node": "0.33.0",
"vitest": "0.33.0"
},
"engines": {
"node": ">= 12"
}
"node": ">=18"
},
"packageManager": "[email protected]"
}
Loading

0 comments on commit 4896810

Please sign in to comment.