robin-cli-tool
v0.5.0
Published
Run scripts for any project
Downloads
33
Readme
Reason
Maintaining a simple JSON file with all the available tasks allows for easy customization of deployment, release, cleaning, and other project-specific actions. This ensures that everyone on the team can use, edit, and add tasks on a project level.
Using robin
The screenshot above was generated based on this robin.json
file at the root of a flutter project:
{
"scripts": {
"clean": "flutter clean && rm-rf ./src/gen/",
"release": "fastlane ios app_distribution release --{{env}} --rollout=1'",
"release testflight": "fastlane ios release -e={{env}}'"
}
}
Will result in the following list:
❯ robin --list
==> clean # flutter clean && rm-rf ./src/gen/
==> release # fastlane ios app_distribution release --{{env}} --rollout=1'
==> release testflight # fastlane ios release -e={{env}}'
No need to re-generate / compile any code, it will read your robin.json
every time you run a command.
Interactive mode
robin --interactive # or "-i"
We can fuzzy search the available tasks (TODO: replace gif)
Install
npm install -g robin-cli-tool
Usage
robin init
Creates a template robin.json
in your current folder.
{
"scripts": {
"clean": "...",
"deploy staging": "echo 'ruby deploy tool --staging'",
"deploy production": "...",
"release beta": "...",
"release alpha": "...",
"release dev": "..."
}
}
Example:
robin release beta # Would run your script to release your app to beta
robin deploy staging # Would deploy your server to staging environment
robin --list # Lists all the available commands
robin --interactive # Interactive search for your available commands
Passing params
By using the following scheme: {{variable}}
=> --variable=XXX
This config:
{
"scripts": {
"clean": "flutter clean && rm-rf ./output/",
"release": "ruby deploy_tool --{{env}}'",
"release testflight": "fastlane ios release -e={{env}}'",
}
}
Makes this possible:
# clean your builds
robin clean
# deploy the app to the store
robin release --env=staging
robin release --env=production
robin release --env=dev
# release an alpha build
robin release testflight --env=alpha
IDEAS (not implemented yet)
Have init templates
robin init --android
robin init --ios
robin init --flutter
robin init --rails
Add
robin add # Adds a command
Example:
robin add "deploy" "fastlane deliver --submit-to-review" # Adds a deploy command to your current list of commands
Created by
License
MIT © Cesar Ferreira