Skip to content

Commit

Permalink
Merge pull request #64 from HiDeoo/hd-autofix
Browse files Browse the repository at this point in the history
  • Loading branch information
HiDeoo authored Dec 9, 2024
2 parents 97226d4 + 71d24d8 commit 05a7e5c
Show file tree
Hide file tree
Showing 11 changed files with 67 additions and 205 deletions.
48 changes: 48 additions & 0 deletions .github/workflows/autofix.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
name: autofix.ci

on:
push:
branches:
- main
pull_request:
branches:
- main
workflow_call:

permissions:
contents: read

concurrency:
cancel-in-progress: true
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request_target' && github.head_ref || github.ref }}

jobs:
autofix:
name: Format code
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: 8.6.1

- name: Install Node.js
uses: actions/setup-node@v4
with:
cache: pnpm
node-version: 18
registry-url: 'https://registry.npmjs.org'

- name: Install dependencies
run: pnpm install

- name: Format code
run: pnpm format

- name: Run autofix
uses: autofix-ci/action@ff86a557419858bb967097bfc916833f5647fa8c
with:
fail-fast: false
6 changes: 5 additions & 1 deletion .github/workflows/integration.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Integration
name: integration

on:
push:
Expand All @@ -9,6 +9,10 @@ on:
- main
workflow_call:

concurrency:
cancel-in-progress: true
group: ${{ github.workflow }}-${{ github.event_name == 'pull_request_target' && github.head_ref || github.ref }}

jobs:
lint_test:
name: Lint & Test
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Release
name: release

on:
push:
Expand Down
4 changes: 0 additions & 4 deletions .husky/pre-commit

This file was deleted.

1 change: 1 addition & 0 deletions docs/astro.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ export default defineConfig({
{ label: 'Demo', link: 'https://starlight-typedoc-example.vercel.app/api/functions/dothingc/' },
],
social: {
blueSky: 'https://bsky.app/profile/hideoo.dev',
github: 'https://github.com/HiDeoo/starlight-typedoc',
},
title: 'Starlight TypeDoc',
Expand Down
3 changes: 2 additions & 1 deletion docs/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"build": "astro build",
"preview": "astro preview",
"astro": "astro",
"lint": "prettier -c --cache . && eslint . --cache --max-warnings=0"
"lint": "eslint . --cache --max-warnings=0",
"format": "prettier -w --cache --ignore-unknown ."
},
"dependencies": {
"@astrojs/starlight": "0.25.0",
Expand Down
4 changes: 4 additions & 0 deletions example/astro.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,10 @@ export default defineConfig({
},
typeDocSidebarGroup,
],
social: {
blueSky: 'https://bsky.app/profile/hideoo.dev',
github: 'https://github.com/HiDeoo/starlight-typedoc',
},
title: 'Starlight TypeDoc Example',
}),
],
Expand Down
3 changes: 2 additions & 1 deletion example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
"build": "astro build",
"preview": "astro preview",
"astro": "astro",
"lint": "prettier -c --cache . && eslint . --cache --max-warnings=0"
"lint": "eslint . --cache --max-warnings=0",
"format": "prettier -w --cache --ignore-unknown ."
},
"dependencies": {
"@astrojs/starlight": "0.25.0",
Expand Down
10 changes: 2 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,15 +8,13 @@
"scripts": {
"test": "pnpm --stream -r test",
"lint": "pnpm -r lint",
"prepare": "husky install"
"format": "pnpm -r format"
},
"devDependencies": {
"@hideoo/eslint-config": "2.0.1",
"@hideoo/prettier-config": "2.0.0",
"@hideoo/tsconfig": "2.0.1",
"eslint": "8.48.0",
"husky": "8.0.3",
"lint-staged": "14.0.1",
"prettier": "3.0.3",
"typescript": "5.1.6"
},
Expand Down Expand Up @@ -47,9 +45,5 @@
"url": "https://github.com/HiDeoo/starlight-typedoc.git"
},
"bugs": "https://github.com/HiDeoo/starlight-typedoc/issues",
"prettier": "@hideoo/prettier-config",
"lint-staged": {
"**/*": "prettier -w -u --cache",
"**/*.{js,jsx,ts,tsx,cjs,mjs}": "eslint --cache --max-warnings=0"
}
"prettier": "@hideoo/prettier-config"
}
3 changes: 2 additions & 1 deletion packages/starlight-typedoc/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,8 @@
"test:e2e:packages": "cross-env TEST_TYPE=packages pnpm run playwright",
"test:e2e:plugins": "cross-env TEST_TYPE=plugins pnpm run playwright",
"playwright": "playwright install --with-deps chromium && playwright test",
"lint": "prettier -c --cache . && eslint . --cache --max-warnings=0"
"lint": "eslint . --cache --max-warnings=0",
"format": "prettier -w --cache --ignore-unknown ."
},
"dependencies": {
"github-slugger": "2.0.0"
Expand Down
Loading

0 comments on commit 05a7e5c

Please sign in to comment.