add `release-plz init` command
MarcoIeni opened this issue · comments
Marco Ieni commented
Motivations
Onboarding is difficult: people need to read the docs to learn how to set up the GitHub action.
Let's change that!
Solution
Add a release-plz init
command to prompt the user and guide them through the onboarding.
It only works if it detects a GitHub repository or no remote is set.
The command will:
- ask the user to copy paste their cargo registry token, tell them that if they don't have it, they can create one at this link: https://crates.io/settings/tokens/new explaining what options are required. After they paste the token and hit enter, release-plz sets the cargo registry token in github actions secret
- ask the user if they want to create a PAT (link to the release-plz github actions section) and set the secret in GitHub actions.
- write to file system the release-plz.yml file
How do we set github actions secrets with the rest api?
why this name?
The name comes from cargo init
.
Tasks
- detect default branch and use that one instead of
main
Marco Ieni commented
implemented in #1350