-
Notifications
You must be signed in to change notification settings - Fork 1
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
1 parent
4698735
commit ecf5862
Showing
1 changed file
with
33 additions
and
3 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,5 +1,35 @@ | ||
# Set Branch name as env var | ||
<h1 align="center">Welcome to github-action-get-branch-name 👋</h1> | ||
<p> | ||
<img alt="Version" src="https://img.shields.io/badge/version-1.0-blue.svg?cacheSeconds=2592000" /> | ||
<a href="https://twitter.com/igordcsouza" target="_blank"> | ||
<img alt="Twitter: igordcsouza" src="https://img.shields.io/twitter/follow/igordcsouza.svg?style=social" /> | ||
</a> | ||
</p> | ||
|
||
Variables needed `TOKEN` with a valid `github_token`! | ||
> This action can help you to get the current branch name when run an action on a feature branch! | ||
The environment name used to set the branch name is `BRANCH_NAME` | ||
## Variables | ||
* TOKEN: A valid Github token. | ||
|
||
## How to use | ||
|
||
``` | ||
- uses: igordcsouza/github-action-get-branch-name@master | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.TOKEN }} | ||
- name: Set branch name as VARIABLE_NAME | ||
run: echo ::set-env name=VARIABLE_NAME::${BRANCH_NAME} | ||
``` | ||
|
||
## Author | ||
|
||
👤 **Igor Souza** | ||
|
||
* Twitter: [@igordcsouza](https://twitter.com/igordcsouza) | ||
|
||
## Show your support | ||
|
||
Give a ⭐️ if this project helped you! | ||
|
||
*** | ||
_This README was generated with ❤️ by [readme-md-generator](https://github.com/kefranabg/readme-md-generator)_ |