Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
bakunyo committed Feb 23, 2019
0 parents commit b34db0d
Show file tree
Hide file tree
Showing 3 changed files with 55 additions and 0 deletions.
15 changes: 15 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
FROM ruby:2.6.1-alpine3.9

LABEL "com.github.actions.name"="git-pr-release"
LABEL "com.github.actions.description"="Run git-pr-release"
LABEL "com.github.actions.icon"="check-square"
LABEL "com.github.actions.color"="green"

LABEL "repository"="https://github.com/bakunyo/git-pr-release-action"
LABEL "maintainer"="bakunyo <izuta.hiroyuki@gmail.com>"

RUN apk add --no-cache git
RUN gem install git-pr-release

ADD entrypoint.sh /entrypoint.sh
ENTRYPOINT ["/entrypoint.sh"]
36 changes: 36 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# git-pr-release-action
GitHub Action to run [git-pr-release](https://github.com/motemen/git-pr-release)

### Usage
For example, here is a workflow to run `git-pr-release` when push to staging.

```
workflow "Create PR to master" {
resolves = ["git-pr-release"]
on = "push"
}
action "Filter branch" {
uses = "actions/bin/filter@24a566c2524e05ebedadef0a285f72dc9b631411"
args = "branch staging"
}
action "git-pr-release" {
uses = "bakunyo/git-pr-release-action@master"
needs = ["Filter branch"]
secrets = [
"GIT_PR_RELEASE_TOKEN",
"GITHUB_TOKEN",
]
}
```

### Secrets(required)
#### `GIT_PR_RELEASE_TOKEN`
Add [GIT_PR_RELEASE_TOKEN](https://github.com/motemen/git-pr-release#pr-releasetoken) as [secret](https://developer.github.com/actions/creating-workflows/storing-secrets/#storing-secrets) to create pull request.

#### `GITHUB_TOKEN`
Add [GITHUB_TOKEN secret](https://developer.github.com/actions/creating-workflows/storing-secrets/#github-token-secret) to make authenticated calls to the GitHub API.

### Environment variables(optional)
Any environment variables defined by [git-pr-release](https://github.com/motemen/git-pr-release) also can use on this action (`GIT_PR_RELEASE_BRANCH_PRODUCTION`, `GIT_PR_RELEASE_BRANCH_STAGING` etc).
4 changes: 4 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh

set -eu
git-pr-release

0 comments on commit b34db0d

Please # to comment.