https://github.com/pforret/bashew_github_action
Use bashew for a Github Action
https://github.com/pforret/bashew_github_action
bashew github-actions
Last synced: about 2 months ago
JSON representation
Use bashew for a Github Action
- Host: GitHub
- URL: https://github.com/pforret/bashew_github_action
- Owner: pforret
- License: mit
- Created: 2022-10-16T17:48:59.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-10-16T21:31:19.000Z (over 3 years ago)
- Last Synced: 2025-08-13T23:34:33.906Z (11 months ago)
- Topics: bashew, github-actions
- Language: Shell
- Homepage:
- Size: 2.97 MB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README


[](https://github.com/pforret/bashew_github_action/actions/workflows/shots.yml)




[](https://www.basher.it/package/)
# bashew_github_action
Use bashew for a Github Action
cf [blog.forret.com/2022/10/15/bashew-github-action/](https://blog.forret.com/2022/10/15/bashew-github-action/)
## 🔥 Usage
```php
Program : bashew_github_action by peter@forret.com
Version : v1.0.0 (2022-10-16 20:42)
Purpose : Use bashew for a Github Action
Usage : bashew_github_action [-h] [-q] [-v] [-f] [-l ] [-t ] [-o ] [-w ] [-h ]
Flags, options and parameters:
-h|--help : [flag] show usage [default: off]
-q|--quiet : [flag] no output [default: off]
-v|--verbose : [flag] also show debug messages [default: off]
-f|--force : [flag] do not ask for confirmation (always yes) [default: off]
-l|--log_dir > : [option] folder for log files [default: log]
-t|--tmp_dir > : [option] folder for temp files [default: tmp]
-o|--out_dir > : [option] folder for output files [default: output]
-w|--width > : [option] screenshot width [default: 1080]
-h|--height > : [option] screenshot height [default: 720]
: [choice] action to perform [options: gha:before,gha:execute,gha:after,check,env,update]
Check for latest version - git@github.com:pforret/bashew_github_action.git
### TIPS & EXAMPLES
* use "bashew_github_action gha:before" to install all necessary software before running the main payload
bashew_github_action gha:before
* use "bashew_github_action gha:execute" to run the main payload of the action
bashew_github_action gha:execute
* use "bashew_github_action gha:after" to check in and commit results to repo
bashew_github_action gha:after
* use "bashew_github_action check" to check if this script is ready to execute and what values the options/flags are
bashew_github_action check
* use "bashew_github_action env" to generate an example .env file
bashew_github_action env > .env
* use "bashew_github_action update" to update to the latest version
bashew_github_action update
* >>> bash script created with pforret/bashew
* >>> for bash development, also check IO:print pforret/setver and pforret/IO:progressbar
```
## ⚡️ Examples
use `bashew` in your Github Actions to do easy preliminary installations, execution and cleanup/commit afterwards.
```yml
jobs:
your-action-name:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
(...)
- name: gha:before
run: |
./bashew_github_action.sh gha:before
- name: gha:execute
run: |
./bashew_github_action.sh gha:execute
- name: gha:after
run: |-
./bashew_github_action.sh gha:after
```
There's an example in the [.github/workflows/shots.yml](https://github.com/pforret/bashew_github_action/blob/master/.github/workflows/shots.yml) for this repo
## 🚀 Installation
with [basher](https://github.com/basherpm/basher)
$ basher install pforret/bashew_github_action
or with `git`
$ git clone https://github.com/pforret/bashew_github_action.git
$ cd bashew_github_action
## 📝 Acknowledgements
* script created with [bashew](https://github.com/pforret/bashew)
© 2022 Peter Forret