-
Notifications
You must be signed in to change notification settings - Fork 17
docs: GitHub Copilotのカスタム指示を追加 #376
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
3a41d8c
docs: GitHub Copilotのカスタム指示を追加
3w36zj6 11d7db5
docs: 翻訳スクリプトのプロンプトを移行
3w36zj6 18032a7
docs: 文言を修正
3w36zj6 b4d13d7
docs: 初回セットアップ手順を追加
3w36zj6 2842ab8
docs: ドキュメント生成に関するパスを修正
3w36zj6 610817b
docs: Webサイト生成の出力先パスを修正
3w36zj6 b7fa40f
docs: プレビューコマンドの説明を修正
3w36zj6 0cfa4a3
docs: クローン手順に具体的なURLを追加
3w36zj6 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 |
|---|---|---|
| @@ -0,0 +1,78 @@ | ||
| # Copilot instructions | ||
|
|
||
| このリポジトリは、[Typst](https://typst.app/)の公式ドキュメントを日本語に翻訳するプロジェクトにおける、コーディングエージェント用の初期セットアップガイドです。エージェントは作業を開始する前に必ずこのファイルを参照し、記載された手順や制約に従ってください。 | ||
|
|
||
| ## リポジトリの概要 | ||
|
|
||
| - リポジトリの目的は、Typstの公式ドキュメントを日本語へ翻訳し、Webサイトとして公開することです。 | ||
| - 依存ツールの管理やタスクランナーとしてmiseを使用します。RustやNode.jsなどのランタイム、jqなどのツールは`mise`で管理されます。 | ||
| - Node.jsのパッケージ管理はBunを使用します。 | ||
| - GitHub Actions(`website.yml`)では、miseタスクを実行し、ビルド、textlint、デプロイを行います。 | ||
|
|
||
| ### 主要なディレクトリの構成 | ||
|
|
||
| - `docs/`: 翻訳対象のMarkdownドキュメントとドキュメントのジェネレーター(typst-docs)。チュートリアル系の文章はここで管理されます。ページ名や見出しの翻訳、リンク解決などは`docs/src/`に書かれたRustコードに依存しており、翻訳者は必要に応じてこのコードを調整します。 | ||
| - `crates/`: 翻訳対象のrustdocドキュメント。リファレンス系の文章はここで管理されます。rustdocのみを編集対象とし、コード本体は変更しません。 | ||
| - `website/`: Webサイトのメタデータと静的サイトジェネレーター(typst-docs-web)。翻訳状況は`website/translation-status.json`で管理されます。 | ||
|
|
||
3w36zj6 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| ## 初回セットアップ | ||
|
|
||
| このリポジトリは`website/typst-docs-web`をGitサブモジュールとして含んでいます(`.gitmodules` を参照)。初めてクローンする場合は以下のいずれかを実行してください。 | ||
|
|
||
| ```bash | ||
| # HTTPS | ||
| git clone --recursive https://github.com/typst-jp/docs.git | ||
|
|
||
| # SSH | ||
| git clone --recursive git@github.com:typst-jp/docs.git | ||
| ``` | ||
|
|
||
| もしすでにクローン済みであれば: | ||
|
|
||
| ```bash | ||
| git submodule update --init --recursive | ||
| ``` | ||
|
|
||
| また、`mise run`を使う前に一度だけ以下を実行してください(詳細は `CONTRIBUTING.md`を参照)。 | ||
|
|
||
| ```bash | ||
| mise trust # このリポジトリの`mise.toml`を信頼 | ||
| mise install # Rust, Node.js, jqなどのツールをインストール | ||
| ``` | ||
|
|
||
| ## 開発の流れ | ||
|
|
||
| 開発や検証は、リポジトリのルートから`mise run`コマンドを使用して行います。 | ||
|
|
||
3w36zj6 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| ### よく使うコマンド | ||
|
|
||
| - `mise run generate`: `docs.json`を再生成し静的Webサイトをビルドします。ドキュメント編集後は必ず実行してください。 | ||
| - `mise run preview`: ビルド済みの成果物をプレビューするサーバー(`http://localhost:4173/docs/`)を起動します。 | ||
| - `mise run textlint-md`: Markdownの文章をtextlintで校正します。 | ||
| - `mise run textlint-html`: 生成されたHTMLの文章をtextlintで校正します。 | ||
3w36zj6 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
|
||
| ## 翻訳の基本方針 | ||
|
|
||
| - `TRANSLATING_GUIDELINES.md`および`docs/glossary.md`を必ず確認し、プロジェクト固有の訳語ルールと方針に厳密に従ってください。 | ||
| - 日本語における標準的なIT技術用語・プログラミング用語を使用して翻訳してください。 | ||
| - 日本語の表現習慣を考慮して、語順を変更し、文の成分を補足して、文が日本語の文脈に合った流暢さを保つようにしてください。 | ||
| - 文脈に応じて固有名詞や多義語の翻訳を決定してください。直接的な日本語の対応語がない単語は原文を保持し、可能な場合は注釈を提供してください。 | ||
| - 流暢で読みやすく、元の情報が完全に保持されるように翻訳してください。 | ||
| - コードブロック中の記述は翻訳しないでください。 | ||
|
|
||
| ## Pull Request作成時の確認事項 | ||
|
|
||
| - `mise run generate`を実行し、ビルドエラーが出ないことを確認する。 | ||
| - `mise run textlint-md`および`mise run textlint-html`を実行して警告を解消する。 | ||
| - 訳語や文法が`TRANSLATING_GUIDELINES.md`や`docs/glossary.md`に沿っているか確認する。 | ||
| - `website/translation-status.json`の翻訳状況を更新する。 | ||
|
|
||
| ## エージェントへの補足 | ||
|
|
||
| - `docs.json`と`assets/`は自動生成されるので、編集やコミットをしてはいけません。 | ||
| - 日本語の表現はtextlintの指摘を尊重してください。設定は`prh.yaml`や`.textlintrc.js`にあります。 | ||
| - miseタスクの詳細は`mise.toml`にあります。 | ||
| - 人間向けの貢献ガイドは`CONTRIBUTING.md`にあります。 | ||
| - `target/`, `node_modules/`フォルダは検索時は無視してください。 | ||
|
|
||
| これらの指示を信頼し、足りない情報や誤りがあれば検索や調査を行ってください。 | ||
This file contains hidden or 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 was deleted.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.