This repository has been archived by the owner on Jul 20, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #32 from albelium/rt/migrate-docs-to-starlight
🎉 ドキュメントアプリを Starlight に変更
- Loading branch information
Showing
48 changed files
with
2,369 additions
and
5,597 deletions.
There are no files selected for viewing
Validating CODEOWNERS rules …
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
# Team 名で指定。 すべてのファイルに web-application-template-maintainers チームの全員が権限を持つ | ||
* @albelium/web-application-template-maintainers | ||
* @albelium/web-application-template-maintainers @albelium-bot[bot] | ||
|
||
# GitHub や Tools 関連は @tatsutakein がオーナとなる | ||
/.github/ @tatsutakein | ||
/.github/ @tatsutakein @albelium-bot[bot] | ||
/scripts/ @tatsutakein | ||
/tools/ @tatsutakein |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,13 +5,17 @@ on: | |
branches: | ||
- main | ||
|
||
concurrency: | ||
group: checks-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
filter: | ||
changed: | ||
runs-on: ubuntu-22.04 | ||
outputs: | ||
check-frontend: ${{ steps.needs.outputs.check-frontend }} | ||
check-backend: ${{ steps.needs.outputs.check-backend }} | ||
check-docs: ${{ steps.needs.outputs.check-docs }} | ||
frontend: ${{ steps.needs.outputs.frontend }} | ||
backend: ${{ steps.needs.outputs.backend }} | ||
docs: ${{ steps.needs.outputs.docs }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
|
@@ -21,104 +25,35 @@ jobs: | |
id: changes | ||
with: | ||
filters: | | ||
check-frontend: | ||
frontend: | ||
- 'apps/frontend/**/*' | ||
- 'packages/eslint-config-custom/**/*' | ||
- 'packages/icon/**/*' | ||
- 'packages/panda-preset/**/*' | ||
- 'packages/tsconfig/**/*' | ||
- 'packages/ui/**/*' | ||
- 'package.json' | ||
check-backend: | ||
backend: | ||
- 'apps/backend/**/*' | ||
- 'packages/eslint-config-custom/**/*' | ||
- 'packages/tsconfig/**/*' | ||
- 'package.json' | ||
check-docs: | ||
docs: | ||
- 'apps/docs/**/*' | ||
- 'packages/eslint-config-custom/**/*' | ||
- 'packages/tsconfig/**/*' | ||
- 'package.json' | ||
- name: Output Needs | ||
id: needs | ||
run: | | ||
echo "check-frontend=${{ steps.changes.outputs.check-frontend == 'true' }}" >> $GITHUB_OUTPUT | ||
echo "check-backend=${{ steps.changes.outputs.check-backend == 'true' }}" >> $GITHUB_OUTPUT | ||
echo "check-docs=${{ steps.changes.outputs.check-docs == 'true' }}" >> $GITHUB_OUTPUT | ||
lint: | ||
runs-on: ubuntu-22.04 | ||
if: ${{ github.event_name == 'pull_request' && github.actor != 'dependabot[bot]' && !startsWith(github.head_ref, 'dependabot/') }} | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
permissions: | ||
contents: read | ||
pull-requests: write | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
with: | ||
fetch-depth: 0 | ||
|
||
- id: app-token | ||
name: Create GitHub App Token | ||
uses: actions/[email protected] | ||
with: | ||
app-id: ${{ vars.BOT_APP_ID }} | ||
private-key: ${{ secrets.BOT_PRIVATE_KEY }} | ||
|
||
- name: Setup pnpm | ||
uses: pnpm/[email protected] | ||
|
||
- name: Clean install using pnpm | ||
shell: bash | ||
run: pnpm install --filter=docs --frozen-lockfile | ||
|
||
- id: require-verified-commits | ||
name: Require verified commits | ||
uses: yumemi-inc/require-verified-commits-action@v1 | ||
continue-on-error: true | ||
|
||
- id: pr-warnings | ||
name: Find existing warnings in the PR | ||
uses: peter-evans/[email protected] | ||
with: | ||
issue-number: "${{ github.event.pull_request.number }}" | ||
body-includes: "<!-- tag:unverified -->" | ||
|
||
- name: Warn unverified commits | ||
if: steps.require-verified-commits.outcome == 'failure' && steps.pr-warnings.outputs.comment-id == '' | ||
run: | | ||
gh pr comment -F - '${{ github.event.pull_request.html_url }}' <<EOS | ||
<!-- tag:unverified --> | ||
@${{ github.event.pull_request.user.login }} | ||
Beep boop... | ||
Pull Request を作成していただきありがとうございます. | ||
突然ですが,この PR に含まれるコミットの一部または全部に署名がされていないようです. | ||
現在の状態では,リポジトリにアクセスできる全員が **あなたになりすましてコミットを作成できます** . | ||
あなたの名前で悪意のあるコミットを作成することも可能といえます. | ||
コミットへの署名は GPG (OpenPGP), S/MIME, または SSH の鍵を使って行えます. | ||
Identity の考え方から GPG の利用を推奨しますが, GitHub ではいずれも Verified となりますので, | ||
ぜひいずれかの設定をお願いします. | ||
コミットへの署名については以下の公式ドキュメントを参照してください: | ||
https://docs.github.com/en/authentication/managing-commit-signature-verification/about-commit-signature-verification | ||
公式ドキュメントではないですが,署名がないことによってなりすましが行えるしくみについては以下で説明されています: | ||
https://qiita.com/s6n/items/bb869f740a53a3bf169e | ||
GPG の設定と運用については以下の記事で詳しく説明されています: | ||
https://qiita.com/shun-shobon/items/a944416bebb6207016fb | ||
Happy Coding! 🔑 | ||
EOS | ||
echo "frontend=${{ steps.changes.outputs.frontend == 'true' }}" >> $GITHUB_OUTPUT | ||
echo "backend=${{ steps.changes.outputs.backend == 'true' }}" >> $GITHUB_OUTPUT | ||
echo "docs=${{ steps.changes.outputs.docs == 'true' }}" >> $GITHUB_OUTPUT | ||
test-frontend: | ||
check-frontend: | ||
runs-on: ubuntu-22.04 | ||
needs: filter | ||
if: needs.filter.outputs.check-frontend == 'true' | ||
needs: changed | ||
if: needs.changed.outputs.frontend == 'true' | ||
permissions: | ||
contents: read | ||
steps: | ||
|
@@ -138,10 +73,10 @@ jobs: | |
- name: Unit Test | ||
run: pnpm run test --filter=frontend... | ||
|
||
test-backend: | ||
check-backend: | ||
runs-on: ubuntu-22.04 | ||
needs: filter | ||
if: needs.filter.outputs.check-backend == 'true' | ||
needs: changed | ||
if: needs.changed.outputs.backend == 'true' | ||
permissions: | ||
contents: read | ||
steps: | ||
|
@@ -161,10 +96,10 @@ jobs: | |
- name: Unit Test | ||
run: pnpm run test --filter=backend... | ||
|
||
test-docs: | ||
check-docs: | ||
runs-on: ubuntu-22.04 | ||
needs: filter | ||
if: needs.filter.outputs.check-docs == 'true' | ||
needs: changed | ||
if: needs.changed.outputs.docs == 'true' | ||
permissions: | ||
contents: read | ||
steps: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,15 +6,15 @@ on: | |
- main | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
group: preview-${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
filter: | ||
changed: | ||
runs-on: ubuntu-22.04 | ||
|
||
outputs: | ||
publish-docs: ${{ steps.needs.outputs.publish-docs }} | ||
docs: ${{ steps.needs.outputs.docs }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
|
@@ -24,18 +24,18 @@ jobs: | |
id: changes | ||
with: | ||
filters: | | ||
publish-docs: | ||
docs: | ||
- 'apps/docs/**/*' | ||
- 'package.json' | ||
- name: Output Needs | ||
id: needs | ||
run: | | ||
echo "publish-docs=${{ steps.changes.outputs.publish-docs == 'true' }}" >> $GITHUB_OUTPUT | ||
echo "docs=${{ steps.changes.outputs.docs == 'true' }}" >> $GITHUB_OUTPUT | ||
publish-docs: | ||
preview-docs: | ||
runs-on: ubuntu-22.04 | ||
needs: filter | ||
if: needs.filter.outputs.publish-docs == 'true' | ||
needs: changed | ||
if: needs.changed.outputs.docs == 'true' | ||
|
||
permissions: | ||
contents: write | ||
|
@@ -74,6 +74,6 @@ jobs: | |
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | ||
accountId: ${{ vars.CLOUDFLARE_ACCOUNT_ID }} | ||
projectName: web-application-template-docs | ||
directory: ./apps/docs/build | ||
directory: ./apps/docs/dist | ||
gitHubToken: ${{ steps.app-token.outputs.token }} | ||
branch: preview${{ github.ref }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,19 +7,19 @@ on: | |
workflow_dispatch: | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
group: ${{ github.ref }} | ||
cancel-in-progress: true | ||
|
||
env: | ||
# 手動実行か否か | ||
IS_DISPATCH: ${{ contains(fromJSON('["workflow_dispatch"]'), github.event_name) }} | ||
|
||
jobs: | ||
filter: | ||
changed: | ||
runs-on: ubuntu-22.04 | ||
|
||
outputs: | ||
publish-docs: ${{ steps.needs.outputs.publish-docs }} | ||
docs: ${{ steps.needs.outputs.docs }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/[email protected] | ||
|
@@ -29,18 +29,18 @@ jobs: | |
id: changes | ||
with: | ||
filters: | | ||
publish-docs: | ||
docs: | ||
- 'apps/docs/**/*' | ||
- 'package.json' | ||
- name: Output Needs | ||
id: needs | ||
run: | | ||
echo "publish-docs=${{ env.IS_DISPATCH == 'true' || steps.changes.outputs.publish-docs == 'true' }}" >> $GITHUB_OUTPUT | ||
echo "docs=${{ env.IS_DISPATCH == 'true' || steps.changes.outputs.docs == 'true' }}" >> $GITHUB_OUTPUT | ||
publish-docs: | ||
runs-on: ubuntu-22.04 | ||
needs: filter | ||
if: needs.filter.outputs.publish-docs == 'true' | ||
needs: changed | ||
if: needs.changed.outputs.docs == 'true' | ||
|
||
permissions: | ||
contents: read | ||
|
@@ -79,6 +79,6 @@ jobs: | |
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }} | ||
accountId: ${{ vars.CLOUDFLARE_ACCOUNT_ID }} | ||
projectName: web-application-template-docs | ||
directory: ./apps/docs/build | ||
directory: ./apps/docs/dist | ||
gitHubToken: ${{ steps.app-token.outputs.token }} | ||
branch: main |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1,21 @@ | ||
# Dependencies | ||
/node_modules | ||
# build output | ||
dist/ | ||
# generated types | ||
.astro/ | ||
|
||
# Production | ||
/build | ||
|
||
# Generated files | ||
.docusaurus | ||
.cache-loader | ||
|
||
# Misc | ||
.DS_Store | ||
.env.local | ||
.env.development.local | ||
.env.test.local | ||
.env.production.local | ||
# dependencies | ||
node_modules/ | ||
|
||
# logs | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
pnpm-debug.log* | ||
|
||
|
||
# environment variables | ||
.env | ||
.env.production | ||
|
||
# macOS-specific files | ||
.DS_Store |
Oops, something went wrong.