stack icon indicating copy to clipboard operation
stack copied to clipboard

`@nxpm/stack:init` should have to option to use a default branch different than `main`

Open ruslanguns opened this issue 3 years ago • 1 comments

Expected Behavior

If you generate a new project and your global default branch is different than main , scripts like affected and format will throw errors.

Current Behavior

Possible Solution

Solution has been commented in the PR #68 -> https://github.com/nxpm/stack/pull/68#issuecomment-762857858

Steps to Reproduce (for bugs)

  1. Having a different default branch name than main globally
  2. generate new project
  3. by running affected or format will throw error
  4. husky will also throw error on new commits

Context

Your Environment

  • Version used: 4.4.6
  • Browser Name and version: n/a
  • Operating System and version (desktop or mobile): Tested on Windows and Linux
  • Link to your project: n/a

ruslanguns avatar Jan 19 '21 14:01 ruslanguns

Updated the description as #68 will now force the initial branch to be main.

Things to do in this change:

  • [ ] @nxpm/stack:init accepts property --defaultBase
  • [ ] nxpm-stack init command from @nxpm/cli accepts property --defaultBase
  • [ ] the --defaultBase option will be passed to yarn create nx-workspace

beeman avatar Jan 19 '21 18:01 beeman