Having a remote named something other than 'origin' breaks `lerna publish`
See original GitHub issueExpected Behavior
In a project with a default branch named something other than 'master'
, and/or a default remote named something other than 'origin'
, I should be able to lerna publish
without receiving an error.
Current Behavior
Attempting lerna publish
yields the following error:
❯ excmd master ⟰ lerna publish
lerna notice cli v3.20.2
lerna info current version 1.0.0-secondary-rollup-package.0
lerna ERR! ENOREMOTEBRANCH Branch 'master' doesn't exist in remote 'origin'.
lerna ERR! ENOREMOTEBRANCH If this is a new branch, please make sure you push it to the remote first.
Possible Solution
Providing a flag to disable the ENOREMOTEBRANCH
checks, or better yet, not hardcoding any assumptions at all about branch/remote names into the tool, would be ideal. ❤️
Steps to Reproduce (for bugs)
lerna.json
{
"packages": ["packages/*"],
"command": {
"bootstrap": {
"hoist": true,
"strict": true,
"nohoist": ["bs-*", "ppx-*", "**/bs-*", "**/ppx-*"]
},
"run": {
"stream": true
}
},
"version": "1.0.0-secondary-rollup-package.0"
}
Executable | Version |
---|---|
lerna --version |
3.20.2 |
npm --version |
6.14.5 |
node --version |
v12.16.0 |
OS | Version |
---|---|
NAME | VERSION |
macOS Big Sur | 11.1 |
Issue Analytics
- State:
- Created 3 years ago
- Reactions:6
- Comments:9
Top Results From Across the Web
Having a remote named something other than 'origin' breaks `lerna ...
In a project with a default branch named something other than 'master' , and/or a default remote named something other than 'origin' ,...
Read more >JavaScript Monorepos with Lerna - Semaphore CI
Publishing your packages. Publishing a package is a two-step process. First, Lerna pushes all the changes to the remote repository and creates ...
Read more >How To Set Up GitHub Actions to Publish a Lerna Monorepo
This will throw if authentication is broken lerna publish will push ... name: Configure CI Git User run: | git remote rm origin...
Read more >Publish Multiple Gatsby Sites in a Monorepo, Using Lerna ...
You may have to run git remote remove origin so you can point the code ... origin git@github.com:<account-name>/lerna-monorepo-starter.git.
Read more >Troubleshooting | Lerna
Make sure to commit all the changes you have in your lerna project, before importing any packages using lerna import . Publish Command....
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
“–git-remote xxx” solved it for me. With it I was able to use a different remote name than origin.
I have the same problem, my reason is the same name of Tag