-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Srg
committed
Dec 11, 2019
1 parent
8b46935
commit 022a1bf
Showing
4 changed files
with
36 additions
and
19 deletions.
There are no files selected for viewing
This file contains 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 |
---|---|---|
@@ -1,14 +1,16 @@ | ||
name: Auto Assign Project Local | ||
|
||
on: [pull_request, issues] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
jobs: | ||
assign_one_project: | ||
runs-on: ubuntu-latest | ||
name: Assign to One Project | ||
steps: | ||
- name: Run assignment to one project | ||
uses: srggrs/assign-one-project-github-action@1.0.4 | ||
uses: srggrs/assign-one-project-github-action@1.1.0 | ||
if: github.event.action == 'opened' | ||
with: | ||
project: 'https://github.com/srggrs/assign-one-project-github-action/projects/2' |
This file contains 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 |
---|---|---|
|
@@ -21,27 +21,50 @@ This action has been modified from the original action from [masutaka](https://g | |
|
||
**Required** The url of the project to be assigned to. | ||
|
||
### `GITHUB_TOKEN` | ||
|
||
**Required** The enviromental variable for query github API. | ||
|
||
## Example usage | ||
|
||
Example of action: | ||
Examples of action: | ||
|
||
### Repository project | ||
|
||
```yaml | ||
name: Auto Assign Project | ||
|
||
on: [pull_request, issues] | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
jobs: | ||
assign_one_project: | ||
runs-on: ubuntu-latest | ||
name: Assign to One Project | ||
steps: | ||
- name: Run assignment to one project | ||
uses: srggrs/assign-one-project-github-action@1.0.4 | ||
if: github.event.action == 'opened' | ||
uses: srggrs/assign-one-project-github-action@1.1.0 | ||
if: github.event.action == 'opened' # not required but speed up the action | ||
with: | ||
project: 'https://github.com/srggrs/assign-one-project-github-action/projects/2' | ||
``` | ||
### Organisation or User project | ||
Generate a token from the Organisation settings or User Settings and add it as a secret in the repository secrets as `MY_GITHUB_TOKEN` | ||
|
||
```yaml | ||
name: Auto Assign Project | ||
on: [pull_request, issues] | ||
env: | ||
MY_GITHUB_TOKEN: ${{ secrets.MY_GITHUB_TOKEN }} | ||
jobs: | ||
assign_one_project: | ||
runs-on: ubuntu-latest | ||
name: Assign to One Project | ||
steps: | ||
- name: Run assignment to one project | ||
uses: srggrs/[email protected] | ||
if: github.event.action == 'opened' # not required but speed up the action | ||
with: | ||
project: 'https://github.com/srggrs/assign-one-project-github-action/projects/2' | ||
``` |
This file contains 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 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