Skip to content

Commit

Permalink
Merge branch 'develop' of github.com:10up/action-pr-helper into depen…
Browse files Browse the repository at this point in the history
…dabot/npm_and_yarn/octokit/action-4.0.9
  • Loading branch information
iamdharmesh committed Oct 14, 2022
2 parents dbd285f + cce77fe commit f724fa5
Show file tree
Hide file tree
Showing 7 changed files with 30 additions and 13 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/check-dist.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
- uses: actions/checkout@v3

- name: Set Node.js 16.x
uses: actions/[email protected].0
uses: actions/[email protected].1
with:
node-version: 16.x

Expand Down
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ All notable changes to this project will be documented in this file, per [the Ke

## [Unreleased] - TBD

## [1.0.0] - TBD
## [1.0.0] - 2022-10-14
### Added
- Initial project release 🎉

Expand Down
4 changes: 2 additions & 2 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ The `develop` branch is the development branch which means it contains the next
## Release instructions

1. Branch: Starting from `develop`, cut a release branch named `release/X.Y.Z` for your changes.
2. Version bump: Bump the version number in `package.json` and any other relevant files if it does not already reflect the version being released.
2. Version bump: Bump the version number in `package.json`, `package-lock.json` and any other relevant files if it does not already reflect the version being released.
3. Changelog: Add/update the changelog in `CHANGELOG.md`.
4. Props: update `CREDITS.md` file with any new contributors, confirm maintainers are accurate.
5. New files: Check to be sure any new files/paths that are unnecessary in the production version are included in `.gitattributes` or `.distignore`.
5. New files: Check to be sure any new files/paths that are unnecessary in the production version are included in `.gitattributes`.
6. Readme updates: Make any other readme changes as necessary.
7. Merge: Make a non-fast-forward merge from your release branch to `develop` (or merge the pull request), then do the same for `develop` into `trunk` (`git checkout trunk && git merge --no-ff develop`). `trunk` contains the stable development version.
8. Push: Push your `trunk` branch to GitHub (e.g. `git push origin trunk`).
Expand Down
2 changes: 1 addition & 1 deletion CREDITS.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ The following individuals are responsible for curating the list of issues, respo

Thank you to all the people who have already contributed to this repository via bug reports, code, design, ideas, project management, translation, testing, etc.

[Dharmesh Patel (@iamdharmesh)](https://github.com/iamdharmesh), [Jeffrey Paul (@jeffpaul)](https://github.com/jeffpaul).
[Dharmesh Patel (@iamdharmesh)](https://github.com/iamdharmesh), [Jeffrey Paul (@jeffpaul)](https://github.com/jeffpaul), [Siddharth Thevaril (@Sidsector9)](https://github.com/Sidsector9).

## Libraries

Expand Down
25 changes: 21 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
# PR Helper - GitHub Action

> GitHub Action that automates some common PR operations like validating PR description, changelog, and credits.
> GitHub Action that automates some common PR operations like validating PR description, changelog and credits.
[![Support Level](https://img.shields.io/badge/support-beta-blueviolet.svg)](#support-level) [![Release Version](https://img.shields.io/github/release/10up/action-pr-helper.svg)](https://github.com/10up/action-pr-helper/releases/latest) [![License](https://img.shields.io/github/license/10up/action-pr-helper.svg)](https://github.com/10up/action-pr-helper/blob/develop/LICENSE.md) [![CodeQL](https://github.com/10up/action-pr-helper/actions/workflows/codeql-analysis.yml/badge.svg)](https://github.com/10up/action-pr-helper/actions/workflows/codeql-analysis.yml)

## Overview

@TODO
This GitHub Action Helps with the following operations:
- **Validate PR description:** It validates PR description to make sure it contains description of the change, changelog and credits. Also, you can set custom comment message for PR author to inform them about PR description requirements.
- **Add Labels:** It helps with adding label to PR when PR validation pass or fail.
- **Auto-assign PR:** It helps with assigning PR to the author.
- **Auto request review:** It helps with request review from the team or GitHub user given in the configuration.

## Configuration

Expand All @@ -22,7 +25,7 @@
| fail-label | `needs:feedback` | The label to be added to PR if the pull request doesn't pass the validation |
| pass-label | `needs:code-review` | The label to be added to PR if the pull request pass the validation |
| comment-template | `{author} thanks for the PR! Could you please fill out the PR template with description, changelog, and credits information so that we can properly review and merge this?` | Comment template for adding comment on PR if it doesn't pass the validation |
| reviewer | `team:open-source-practice` | Reviewer to request review after passing all validation checks. Add prefix `team:` if you want to assign PR to team.
| reviewer | `team:open-source-practice` | Reviewer to request review after passing all validation checks. Add prefix `team:` if you want to request review from the team.

## Example Workflow File

Expand All @@ -48,10 +51,24 @@ jobs:
with:
fail-label: 'needs:feedback'
pass-label: 'needs:code-review'
reviewer: GITHUB_USERNAME
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
```
### (Optional) GitHub Personal Access Token (PAT)
When the default `GITHUB_TOKEN` doesn't have the necessary permissions, you need to create a new GitHub personal access token.

For example, if you'd like to request a review from **GitHub teams**, you need to create a new PAT because the default `GITHUB_TOKEN` doesn't have the permission to request a review from a team.

The PAT needs to have the `repo` scope and the account used for create a `PAT` needs to have the write permission to the repository. Once you create a new PAT, set it as a secret in your repository.

You have to pass your `PAT` to `GITHUB_TOKEN` environment variable, as below.
```yml
env:
GITHUB_TOKEN: ${{ secrets.PAT }}
```

## Support Level

**Beta:** This project is quite new and we're not sure what our ongoing support level for this will be. Bug reports, feature requests, questions, and pull requests are welcome. If you like this project please let us know, but be cautious using this in a Production environment!
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "10up/action-pr-helper",
"version": "0.0.1",
"description": "GH Action for automate some common PR operations and validate PR description, changelog and credits.",
"version": "1.0.0",
"description": "GitHub Action to automate some common PR operations and validate PR description, changelog and credits.",
"keywords": [
"GitHub",
"Actions",
Expand Down

0 comments on commit f724fa5

Please sign in to comment.