From b45597c47e9b1a5c9b312938facca87f8e140623 Mon Sep 17 00:00:00 2001 From: roottool Date: Sun, 19 Jul 2026 17:01:25 +0900 Subject: [PATCH 1/2] ci: Add dprint formatter for markdown, yaml, and toml Introduce dprint (markdown/toml/pretty_yaml plugins) as a unified formatter for md/yaml/toml files, mirroring the shfmt/ShellCheck formatter+linter split already used for shell scripts. markdownlint keeps its existing linting role for markdown. Co-Authored-By: Claude Sonnet 5 --- .github/ISSUE_TEMPLATE/bug_report.md | 1 - .github/ISSUE_TEMPLATE/feature_request.md | 1 - .github/workflows/assign.yml | 4 +-- .github/workflows/ci.yaml | 33 ++++++++++++++--------- README.md | 16 +++++------ dprint.json | 13 +++++++++ 6 files changed, 44 insertions(+), 24 deletions(-) create mode 100644 dprint.json diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 6e8459b..e9643f2 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -4,7 +4,6 @@ about: Create a report to help us improve title: '' labels: bug assignees: '' - --- **Describe the bug** diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index 11fc491..5f0a04c 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -4,7 +4,6 @@ about: Suggest an idea for this project title: '' labels: enhancement assignees: '' - --- **Is your feature request related to a problem? Please describe.** diff --git a/.github/workflows/assign.yml b/.github/workflows/assign.yml index 399d66d..cd28590 100644 --- a/.github/workflows/assign.yml +++ b/.github/workflows/assign.yml @@ -1,5 +1,5 @@ -name: "Auto Assign" -run-name: "${{ github.workflow }} (${{ github.ref_name }}): ${{ github.event.pull_request.title }}" +name: 'Auto Assign' +run-name: '${{ github.workflow }} (${{ github.ref_name }}): ${{ github.event.pull_request.title }}' on: pull_request: types: [opened, reopened, ready_for_review] diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 92cd3ae..9b1709e 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -22,6 +22,7 @@ jobs: markdown: ${{ steps.filter.outputs.markdown }} markdown_files: ${{ steps.filter.outputs.markdown_files }} shellscript: ${{ steps.filter.outputs.shellscript }} + dprint: ${{ steps.filter.outputs.dprint }} if: ${{ !github.event.pull_request.draft }} steps: - name: Assign yourself to this PR @@ -50,6 +51,11 @@ jobs: - 'dot_profile' - 'dot_zprofile' - 'dot_zsh*' + dprint: + - '**/*.md' + - '**/*.yaml' + - '**/*.yml' + - '**/*.toml' lint: name: Lint @@ -65,19 +71,22 @@ jobs: if: ${{ needs.setup.outputs.shellscript == 'true' }} uses: mfinelli/setup-shfmt@a25fda4c1fe115aec0f85e04126610841bc3141d # v4.0.1 with: - shfmt-version: "3.13.1" + shfmt-version: '3.13.1' - parallel: - - name: Check formatting (shfmt) - if: ${{ needs.setup.outputs.shellscript == 'true' }} - run: find . -type f \( -name 'dot_profile' -o -name 'dot_z*' -o -name '*.sh' -o -name '*.zsh' \) | grep -Ev 'examples/*' | xargs shfmt -d - - name: ShellCheck - if: ${{ needs.setup.outputs.shellscript == 'true' }} - run: find . -type f \( -name 'dot_profile' -o -name 'dot_z*' -o -name '*.sh' -o -name '*.zsh' \) | grep -Ev 'examples/*' | xargs shellcheck - - name: Markdown lint - if: ${{ needs.setup.outputs.markdown == 'true' }} - uses: DavidAnson/markdownlint-cli2-action@8de2aa07cae85fd17c0b35642db70cf5495f1d25 # v24.0.0 - with: - globs: ${{ needs.setup.outputs.markdown_files }} + - name: Check formatting (shfmt) + if: ${{ needs.setup.outputs.shellscript == 'true' }} + run: find . -type f \( -name 'dot_profile' -o -name 'dot_z*' -o -name '*.sh' -o -name '*.zsh' \) | grep -Ev 'examples/*' | xargs shfmt -d + - name: ShellCheck + if: ${{ needs.setup.outputs.shellscript == 'true' }} + run: find . -type f \( -name 'dot_profile' -o -name 'dot_z*' -o -name '*.sh' -o -name '*.zsh' \) | grep -Ev 'examples/*' | xargs shellcheck + - name: Markdown lint + if: ${{ needs.setup.outputs.markdown == 'true' }} + uses: DavidAnson/markdownlint-cli2-action@8de2aa07cae85fd17c0b35642db70cf5495f1d25 # v24.0.0 + with: + globs: ${{ needs.setup.outputs.markdown_files }} + - name: Check formatting (dprint) + if: ${{ needs.setup.outputs.dprint == 'true' }} + uses: dprint/check@9cb3a2b17a8e606d37aae341e49df3654933fc23 # v2.3 test: name: Test diff --git a/README.md b/README.md index 2410d8d..3d727da 100644 --- a/README.md +++ b/README.md @@ -37,10 +37,10 @@ This dotfiles repository is intended to be used for Debian or Ubuntu under WSL2. 4. Move to the cloned repository 5. Execute the install script - ```bash - chmod +x install-packages.sh - ./install-packages.sh - ``` + ```bash + chmod +x install-packages.sh + ./install-packages.sh + ``` 6. Reboot your distribution 7. Make a GPG key for GitHub. @@ -50,10 +50,10 @@ This dotfiles repository is intended to be used for Debian or Ubuntu under WSL2. 8. Download [Gpg4win](https://www.gpg4win.org/) 9. Create `~/.gnupg/gpg-agent.conf` - ```bash - touch ~/.gnupg/gpg-agent.conf - gpg-connect-agent reloadagent /bye - ``` + ```bash + touch ~/.gnupg/gpg-agent.conf + gpg-connect-agent reloadagent /bye + ``` 10. Reboot a gpg agent diff --git a/dprint.json b/dprint.json new file mode 100644 index 0000000..24e2067 --- /dev/null +++ b/dprint.json @@ -0,0 +1,13 @@ +{ + "yaml": { + "quotes": "preferSingle" + }, + "excludes": [ + ".serena/" + ], + "plugins": [ + "https://plugins.dprint.dev/markdown-0.22.1.wasm", + "https://plugins.dprint.dev/toml-0.7.0.wasm", + "https://plugins.dprint.dev/g-plane/pretty_yaml-v0.6.0.wasm" + ] +} From 227fc5b013ab1f13b1530fea6b635a66bb78d4c4 Mon Sep 17 00:00:00 2001 From: roottool Date: Sun, 19 Jul 2026 17:05:12 +0900 Subject: [PATCH 2/2] chore: Add CLAUDE.md and AGENTS.md --- .chezmoiignore | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.chezmoiignore b/.chezmoiignore index db7f4f3..f965e5c 100644 --- a/.chezmoiignore +++ b/.chezmoiignore @@ -8,6 +8,8 @@ README.md CODEOWNERS .serena +AGENTS.md +CLAUDE.md # VS Code ## Workspace file for local