-
Notifications
You must be signed in to change notification settings - Fork 3
chore(.github): add github actions #30
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
Closed
Closed
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
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 was deleted.
Oops, something went wrong.
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,30 @@ | ||
| name: "🐛 Bug Report" | ||
| description: "Report a bug in the application" | ||
| labels: [bug] | ||
| body: | ||
| - type: markdown | ||
| attributes: | ||
| value: | | ||
| ## Describe the Bug | ||
| - type: textarea | ||
| id: bug-description | ||
| attributes: | ||
| label: "What happened?" | ||
| description: "Describe what the bug is, and how to reproduce it." | ||
| placeholder: "Steps to reproduce the bug..." | ||
| - type: textarea | ||
| id: steps-to-reproduce | ||
| attributes: | ||
| label: "Steps to Reproduce" | ||
| description: | | ||
| 1. Go to '...' | ||
| 2. Click on '...' | ||
| 3. Scroll down to '...' | ||
| 4. See error | ||
| placeholder: "List the steps to reproduce the bug..." | ||
| - type: input | ||
| id: environment | ||
| attributes: | ||
| label: "Environment (OS, Node.js, pnpm, Project version)" | ||
| description: "Provide details about your environment to help with debugging." | ||
| placeholder: "e.g. Ubuntu 20.04, Node.js 16.13.0, pnpm 6.14.5, v1.2.3" |
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,4 @@ | ||
| contact_links: | ||
| - name: 📬 Contact the Team | ||
| url: https://github.com/ansopedia/notification-service/discussions | ||
| about: Ask questions, suggest ideas, or start a discussion |
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,38 @@ | ||
| name: "✨ Feature Request" | ||
| description: "Suggest a new feature or enhancement" | ||
| labels: [enhancement] | ||
| body: | ||
| - type: markdown | ||
| attributes: | ||
| value: | | ||
| ## Feature Summary | ||
| - type: textarea | ||
| id: feature-summary | ||
| attributes: | ||
| label: "Summary" | ||
| description: "Provide a short summary of the feature or enhancement." | ||
| placeholder: "Briefly describe the feature..." | ||
| - type: textarea | ||
| id: motivation | ||
| attributes: | ||
| label: "Motivation" | ||
| description: "Explain why this feature is needed and the problem it solves." | ||
| placeholder: "Why is this feature important?" | ||
| - type: textarea | ||
| id: proposed-solution | ||
| attributes: | ||
| label: "Proposed Solution" | ||
| description: "Describe the solution or approach you suggest." | ||
| placeholder: "How would you implement this feature?" | ||
| - type: textarea | ||
| id: alternatives | ||
| attributes: | ||
| label: "Alternatives Considered" | ||
| description: "List any alternative solutions or features you considered." | ||
| placeholder: "Other options you considered..." | ||
| - type: input | ||
| id: environment | ||
| attributes: | ||
| label: "Environment (OS, Node.js, pnpm, Project version)" | ||
| description: "Provide details about your environment to help with debugging." | ||
| placeholder: "e.g. Ubuntu 20.04, Node.js 16.13.0, pnpm 6.14.5, v1.2.3" |
This file was deleted.
Oops, something went wrong.
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,11 @@ | ||
| What was the bug? How was it fixed? | ||
|
|
||
| ## 🔗 Related Issues | ||
|
|
||
| Link any issues this PR fixes. | ||
|
|
||
| ## ✅ Checklist | ||
|
|
||
| - [ ] Bug is fixed | ||
| - [ ] Regressions tested | ||
| - [ ] Lint and tests pass |
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,12 @@ | ||
| Describe the new feature and its purpose. | ||
|
|
||
| ## 📌 Related Issues / Tasks | ||
|
|
||
| Link any related issues or task IDs. | ||
|
|
||
| ## ✅ Checklist | ||
|
|
||
| - [ ] Feature works as expected | ||
| - [ ] Code is linted and formatted | ||
| - [ ] Tests have been written | ||
| - [ ] Docs are updated if needed |
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,20 @@ | ||
| Describe the changes made for code cleanup, restructuring, or optimization. | ||
| Clearly mention if the behavior or logic remains unchanged. | ||
|
|
||
| ## 📂 Why Refactor? | ||
|
|
||
| Explain the motivation behind the refactor. | ||
| For example: improve readability, performance, maintainability, or remove duplication. | ||
|
|
||
| ## 🔗 Related Issues / Tasks | ||
|
|
||
| Link any related issue, task, or technical debt ticket. | ||
|
|
||
| ## ✅ Checklist | ||
|
|
||
| - [ ] No breaking changes introduced | ||
| - [ ] Code behavior remains consistent (if applicable) | ||
| - [ ] Code is cleaner and easier to maintain | ||
| - [ ] All tests still pass | ||
| - [ ] New tests added for refactored parts (if needed) | ||
| - [ ] Documentation updated (if needed) |
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,7 @@ | ||
| 👋 **Please select the appropriate PR template from the list.** | ||
|
|
||
| - [New Feature](./PULL_REQUEST_TEMPLATE/feature_template.md) | ||
| - [Bug Fix](./PULL_REQUEST_TEMPLATE/bugfix_template.md) | ||
| - [Refactor](./PULL_REQUEST_TEMPLATE/refactor_template.md) | ||
|
|
||
| _Ensure your PR title starts with `[feature]`, `[bugfix]`, or `[refactor]` so labels are added automatically._ | ||
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,34 @@ | ||
| name: 🔖 Label PRs by Title | ||
|
|
||
| on: | ||
| pull_request: | ||
| types: [opened, edited, reopened, synchronize] | ||
|
|
||
| jobs: | ||
| labeler: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - name: 🏷️ Add labels based on PR title | ||
| uses: actions/github-script@v7 | ||
| with: | ||
| github-token: ${{ secrets.GITHUB_TOKEN }} | ||
| script: | | ||
| const title = context.payload.pull_request.title.toLowerCase(); | ||
| const labels = []; | ||
|
|
||
| if (title.startsWith('[feature]')) { | ||
| labels.push('type:feature'); | ||
| } else if (title.startsWith('[bugfix]')) { | ||
| labels.push('type:bugfix'); | ||
| } else if (title.startsWith('[refactor]')) { | ||
| labels.push('type:refactor'); | ||
| } | ||
|
|
||
| if (labels.length > 0) { | ||
| await github.rest.issues.addLabels({ | ||
| owner: context.repo.owner, | ||
| repo: context.repo.repo, | ||
| issue_number: context.payload.pull_request.number, | ||
| labels | ||
| }); | ||
| } |
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 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 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 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
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The links to the PR templates are currently relative file paths. While this works for browsing the repository, a more user-friendly approach for PR creation is to use query parameters. This allows users to click a link and have the corresponding template pre-filled on the 'New Pull Request' page.