@kurokeita/add-skill 1.12.0 → 1.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,112 @@
1
+ ---
2
+ name: git-convention
3
+ description: This skill should be used when the user asks to "create a branch", "commit changes", "create a pull request", "manage branches", or "follow conventional commits". Provides guidelines for version control workflows and commit message formatting.
4
+ version: 1.0.0
5
+ ---
6
+
7
+ # Git Convention
8
+
9
+ Guide for managing version control workflows, including branching strategies, commit message formatting following Conventional Commits, and pull request management.
10
+
11
+ ## When to Use This Skill
12
+
13
+ - Creating new feature, bugfix, or maintenance branches
14
+ - Formatting commit messages to follow project standards
15
+ - Preparing and creating pull requests
16
+ - Managing branch lifecycle and cleanup
17
+ - Ensuring consistency across the repository's history
18
+
19
+ ## Branching Strategy
20
+
21
+ Follow a consistent naming convention for branches to ensure clarity and organization.
22
+
23
+ ### Branch Naming Convention
24
+
25
+ Use a prefix followed by a descriptive name in kebab-case:
26
+
27
+ - `feature/` - New features or significant functional additions (e.g., `feature/user-authentication`)
28
+ - `fix/` - Bug fixes and patches (e.g., `fix/login-error`)
29
+ - `refactor/` - Code restructuring without changing behavior (e.g., `refactor/api-client`)
30
+ - `docs/` - Documentation updates (e.g., `docs/update-readme`)
31
+ - `chore/` - Maintenance tasks, dependency updates, or internal tooling (e.g., `chore/update-deps`)
32
+ - `test/` - Adding or modifying tests (e.g., `test/unit-tests-auth`)
33
+
34
+ ### Workflow
35
+
36
+ 1. Start from the main integration branch (e.g., `main` or `develop`).
37
+ 2. Ensure the local branch is up-to-date: `git pull origin main`.
38
+ 3. Create the new branch: `git checkout -b <prefix>/<description>`.
39
+
40
+ ## Conventional Commits
41
+
42
+ Format commit messages according to the [Conventional Commits](https://www.conventionalcommits.org/) specification to enable automated changelog generation and easier history browsing.
43
+
44
+ ### Structure
45
+
46
+ ```
47
+ <type>(<scope>): <description>
48
+
49
+ [optional body]
50
+
51
+ [optional footer(s)]
52
+ ```
53
+
54
+ ### Types
55
+
56
+ - `feat`: A new feature
57
+ - `fix`: A bug fix
58
+ - `docs`: Documentation only changes
59
+ - `style`: Changes that do not affect the meaning of the code (white-space, formatting, missing semi-colons, etc.)
60
+ - `refactor`: A code change that neither fixes a bug nor adds a feature
61
+ - `perf`: A code change that improves performance
62
+ - `test`: Adding missing tests or correcting existing tests
63
+ - `build`: Changes that affect the build system or external dependencies (example scopes: gulp, broccoli, npm)
64
+ - `ci`: Changes to our CI configuration files and scripts (example scopes: Travis, Circle, BrowserStack, SauceLabs)
65
+ - `chore`: Other changes that don't modify src or test files
66
+ - `revert`: Reverts a previous commit
67
+
68
+ ### Guidelines
69
+
70
+ - **Description**: Use the imperative, present tense (e.g., "add", not "added" or "adds").
71
+ - **Case**: The description should be in lower-case or sentence-case.
72
+ - **Scope**: Use a scope to provide additional contextual information (e.g., `feat(auth): add login validation`).
73
+ - **Body**: Use the body to explain the "what" and "why" of the change, not the "how".
74
+ - **Footer**: Use the footer to reference issues (e.g., `Closes #123`) or breaking changes.
75
+
76
+ ## Pull Request Management
77
+
78
+ Create clear and informative pull requests to facilitate effective code review and collaboration.
79
+
80
+ ### PR Creation Process
81
+
82
+ 1. **Push your branch**: `git push origin <branch-name>`.
83
+ 2. **Open the PR**: Use the GitHub CLI or web interface.
84
+ 3. **Title**: Use the Conventional Commits format for the title (e.g., `feat(ui): add dashboard widgets`).
85
+ 4. **Description**: Use a template (if available) to describe:
86
+ - What changes were made.
87
+ - Why they were made.
88
+ - How they were tested.
89
+ - Any breaking changes or new dependencies.
90
+
91
+ ### Best Practices
92
+
93
+ - **Keep it focused**: One PR per logical change. Avoid "mega-PRs".
94
+ - **Self-review**: Review your own changes before asking others.
95
+ - **Link issues**: Use keywords like `Fixes #123` or `Closes #123` in the description.
96
+ - **Update regularly**: Rebase or merge from the main branch if the PR becomes stale.
97
+
98
+ ## Additional Resources
99
+
100
+ ### Reference Files
101
+
102
+ For detailed patterns and advanced git workflows, consult:
103
+
104
+ - **`references/conventional-commits.md`** - Detailed Conventional Commits specification.
105
+ - **`references/branching-workflows.md`** - Advanced branching and merging strategies.
106
+
107
+ ### Example Files
108
+
109
+ Working examples in `examples/`:
110
+
111
+ - **`commit-messages.txt`** - Examples of well-formatted commit messages.
112
+ - **`pr-description-template.md`** - A standard PR description template.
@@ -0,0 +1,34 @@
1
+ # Example Commit Messages
2
+
3
+ ## Features
4
+ - `feat(ui): add progress bar component`
5
+ - `feat(auth): implement oauth2 login with google`
6
+ - `feat!: change default api version to v2`
7
+
8
+ ## Bug Fixes
9
+ - `fix(parser): handle empty input string gracefully`
10
+ - `fix: resolve race condition in database connection pool`
11
+ - `fix(styles): fix padding issues on mobile devices`
12
+
13
+ ## Documentation
14
+ - `docs: update readme with installation instructions`
15
+ - `docs(api): document the new /user/profile endpoint`
16
+ - `docs: add contributing guide`
17
+
18
+ ## Refactoring
19
+ - `refactor(core): simplify the request handling logic`
20
+ - `refactor: move utility functions to a separate module`
21
+ - `refactor(tests): reduce duplication in integration tests`
22
+
23
+ ## Performance
24
+ - `perf(image): optimize image loading speed using lazy-loading`
25
+ - `perf: add caching layer for frequently accessed data`
26
+
27
+ ## Tests
28
+ - `test(auth): add unit tests for jwt validation`
29
+ - `test: increase coverage for the math module`
30
+
31
+ ## Chore
32
+ - `chore: update dependencies`
33
+ - `chore(deps): bump vite from 4.0 to 5.0`
34
+ - `chore: remove unused log statements`
@@ -0,0 +1,40 @@
1
+ ## Summary
2
+ <!-- Explain the **motivation** for making this change. What existing problem does the pull request solve? -->
3
+
4
+ ## Related Issue
5
+ <!-- Link to the issue this PR addresses (e.g., Fixes #123, Closes #456) -->
6
+ Fixes #
7
+
8
+ ## Type of Change
9
+ <!-- Please delete options that are not relevant -->
10
+ - [ ] Bug fix (non-breaking change which fixes an issue)
11
+ - [ ] New feature (non-breaking change which adds functionality)
12
+ - [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
13
+ - [ ] Documentation update
14
+ - [ ] Refactor (code change that neither fixes a bug nor adds a feature)
15
+
16
+ ## How did you test this change?
17
+ <!--
18
+ Please describe the tests that you ran to verify your changes.
19
+ Provide instructions so we can reproduce.
20
+ Please also list any relevant details for your test configuration.
21
+ -->
22
+ - [ ] Test Case A: ...
23
+ - [ ] Test Case B: ...
24
+
25
+ ### Screenshots (if applicable)
26
+ <!-- Add images to show visual changes -->
27
+
28
+ ## Checklist
29
+
30
+ - [ ] I have read the [CONTRIBUTING](CONTRIBUTING.md) document.
31
+ - [ ] My code follows the code style of this project.
32
+ - [ ] I have performed a self-review of my own code.
33
+ - [ ] I have commented my code, particularly in hard-to-understand areas.
34
+ - [ ] I have made corresponding changes to the documentation.
35
+ - [ ] My changes generate no new warnings.
36
+ - [ ] I have added tests that prove my fix is effective or that my feature works.
37
+ - [ ] New and existing unit tests pass locally with my changes.
38
+
39
+ ## Special notes for your reviewer
40
+ <!-- Any specific areas you want the reviewer to focus on? -->
@@ -0,0 +1,63 @@
1
+ # Advanced Branching and Merging Strategies
2
+
3
+ Choosing the right branching strategy is crucial for team collaboration and continuous delivery.
4
+
5
+ ## Gitflow Workflow
6
+
7
+ Gitflow is a legacy Git workflow that was first published and made popular by Vincent Driessen. It's often used for projects that have a scheduled release cycle.
8
+
9
+ - `main` branch stores the official release history.
10
+ - `develop` branch serves as an integration branch for features.
11
+ - `feature/*` branches are used for developing new features.
12
+ - `release/*` branches support preparation of a new production release.
13
+ - `hotfix/*` branches are used to quickly patch production releases.
14
+
15
+ ## GitHub Flow
16
+
17
+ GitHub Flow is a lightweight, branch-based workflow that supports teams and projects where deployments happen regularly.
18
+
19
+ - Anything in the `main` branch is deployable.
20
+ - To work on something new, create a descriptive branch off of `main`.
21
+ - Commit to that branch locally and regularly push your work to the same named branch on the server.
22
+ - When you need feedback or help, or you think the branch is ready for merging, open a pull request.
23
+ - After someone else has reviewed and signed off on the feature, you can merge it into `main`.
24
+ - Once it is merged and pushed to `main`, you can and should deploy immediately.
25
+
26
+ ## Trunk-Based Development
27
+
28
+ A version control management strategy where developers merge small, frequent updates to a core “trunk” or main branch.
29
+
30
+ - High frequency of commits.
31
+ - Small PRs.
32
+ - Continuous Integration.
33
+ - Feature flags are often used to hide work-in-progress.
34
+
35
+ ## Merging vs Rebasing
36
+
37
+ ### Merging
38
+
39
+ `git merge` is a "non-destructive" operation. The existing branches are not changed in any way. This avoids all of the potential pitfalls of rebasing.
40
+
41
+ ```bash
42
+ git checkout feature/abc
43
+ git merge main
44
+ ```
45
+
46
+ ### Rebasing
47
+
48
+ `git rebase` moves the entire feature branch to begin on the tip of the `main` branch, effectively incorporating all of the new commits in `main`. It re-writes the project history by creating brand new commits for each commit in the original branch.
49
+
50
+ ```bash
51
+ git checkout feature/abc
52
+ git rebase main
53
+ ```
54
+
55
+ **Golden Rule of Rebasing**: Never use it on public branches.
56
+
57
+ ## Conflict Resolution
58
+
59
+ 1. Identify the conflict: `git status` will show unmerged paths.
60
+ 2. Open the files and look for `<<<<<<<`, `=======`, `>>>>>>>`.
61
+ 3. Decide which changes to keep.
62
+ 4. Stage the resolved files: `git add <file>`.
63
+ 5. Complete the merge or rebase: `git commit` or `git rebase --continue`.
@@ -0,0 +1,85 @@
1
+ # Conventional Commits Specification
2
+
3
+ The Conventional Commits specification is a lightweight convention on top of commit messages. It provides an easy set of rules for creating an explicit commit history; which makes it easier to write automated tools on top of.
4
+
5
+ ## The Specification
6
+
7
+ The commit message should be structured as follows:
8
+
9
+ ```
10
+ <type>[optional scope]: <description>
11
+
12
+ [optional body]
13
+
14
+ [optional footer(s)]
15
+ ```
16
+
17
+ ### Type
18
+
19
+ The type is a short string that describes the category of the change. Common types include:
20
+
21
+ - `feat`: (feature)
22
+ - `fix`: (bug fix)
23
+ - `docs`: (documentation)
24
+ - `style`: (formatting, missing semi-colons, etc; no code change)
25
+ - `refactor`: (refactoring production code)
26
+ - `test`: (adding missing tests, refactoring tests; no production code change)
27
+ - `chore`: (updating grunt tasks etc; no production code change)
28
+
29
+ ### Scope
30
+
31
+ A scope MAY be provided after a type. A scope MUST consist of a noun describing a section of the codebase surrounded by parenthesis, e.g., `fix(parser):`
32
+
33
+ ### Description
34
+
35
+ The description contains a succinct description of the change:
36
+
37
+ - use the imperative, present tense: "change" not "changed" nor "changes"
38
+ - don't capitalize the first letter
39
+ - no dot (.) at the end
40
+
41
+ ### Body
42
+
43
+ A longer commit body MAY be provided after the short description, providing additional contextual information about the code changes. The body MUST begin one blank line after the description.
44
+
45
+ ### Footer
46
+
47
+ One or more footers MAY be provided one blank line after the body. Each footer MUST consist of a word token, followed by either a `:<space>` or `<space>#` separator, followed by a string value (this is inspired by the git trailer convention).
48
+
49
+ ### Breaking Changes
50
+
51
+ A breaking change MUST be indicated by an `!` after the type/scope, or as a footer entry starting with `BREAKING CHANGE:`.
52
+
53
+ ## Examples
54
+
55
+ ### Commit message with description and breaking change footer
56
+
57
+ ```
58
+ feat: allow provided config object to extend other configs
59
+
60
+ BREAKING CHANGE: `extends` key in config file is now used for extending other config files
61
+ ```
62
+
63
+ ### Commit message with ! to draw attention to breaking change
64
+
65
+ ```
66
+ feat!: send an email to the customer when a product is shipped
67
+ ```
68
+
69
+ ### Commit message with scope and ! to draw attention to breaking change
70
+
71
+ ```
72
+ chore(api)!: drop support for Node 6
73
+ ```
74
+
75
+ ### Commit message with multi-paragraph body and multiple footers
76
+
77
+ ```
78
+ fix: prevent racing of requests
79
+
80
+ Introduce a request id and a reference to latest request. All
81
+ rest responses are checked against the current id before update.
82
+
83
+ Reviewers: adrian, jdoe
84
+ Fixes #123
85
+ ```
@@ -0,0 +1,66 @@
1
+ # Pull Request Description Best Practices
2
+
3
+ A well-crafted pull request (PR) description is essential for effective code review, maintaining project history, and ensuring that changes meet quality standards.
4
+
5
+ ## Core Components
6
+
7
+ The most effective PR templates across major open-source repositories (like React, VS Code, and Kubernetes) share these core components:
8
+
9
+ ### 1. Summary & Motivation
10
+
11
+ Explain **what** you changed and **why** you changed it.
12
+
13
+ - What problem does this PR solve?
14
+ - What is the context for this change?
15
+ - Are there any architectural decisions or trade-offs made?
16
+
17
+ ### 2. Related Issues
18
+
19
+ Always link to the issue(s) being addressed. Use keywords that GitHub recognizes to automatically close issues when the PR is merged:
20
+
21
+ - `Fixes #123`
22
+
23
+ - `Closes #123`
24
+
25
+ - `Resolves #123`
26
+
27
+ ### 3. Type of Change
28
+
29
+ Categorize the PR to help maintainers quickly understand its impact:
30
+
31
+ - **Bug Fix**: Non-breaking change that fixes an issue.
32
+
33
+ - **New Feature**: Non-breaking change that adds functionality.
34
+
35
+ - **Breaking Change**: Fix or feature that would cause existing functionality to change.
36
+ - **Documentation**: Changes to documentation only.
37
+ - **Refactor**: Code change that neither fixes a bug nor adds a feature.
38
+
39
+ ### 4. Test Plan (Verification)
40
+
41
+ Describe how you verified your changes. This is the most critical section for reviewers.
42
+
43
+ - **Automated Tests**: Mention new or existing tests that cover the changes.
44
+ - **Manual Testing**: List the steps taken to manually verify the behavior.
45
+ - **Screenshots/Gifs**: Provide visual evidence for UI/UX changes.
46
+
47
+ ### 5. Checklist
48
+
49
+ A set of mandatory steps the contributor must confirm:
50
+
51
+ - [ ] My code follows the project's style guidelines.
52
+ - [ ] I have performed a self-review of my code.
53
+ - [ ] I have added tests that cover my changes.
54
+ - [ ] All new and existing tests passed.
55
+ - [ ] I have updated the documentation accordingly.
56
+
57
+ ### 6. Special Notes for Reviewers
58
+
59
+ Use this section to highlight specific areas where you need feedback or to explain complex logic that might be hard to follow.
60
+
61
+ ## Best Practices
62
+
63
+ - **Keep it focused**: One logical change per PR. Small PRs are easier to review and less likely to introduce bugs.
64
+ - **Write for the future**: Your PR description will be part of the repository's history. Write it so that someone reading it a year from now can understand the context.
65
+ - **Be concise but thorough**: Avoid "fluff," but don't leave out critical information.
66
+ - **Update the description**: If the PR evolves during the review process, update the description to reflect the final state of the changes.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kurokeita/add-skill",
3
- "version": "1.12.0",
3
+ "version": "1.13.0",
4
4
  "description": "CLI to install AI agent skills to various platforms",
5
5
  "type": "module",
6
6
  "bin": {