Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
Comments on Possible drawbacks for having duplicate local sources of the project tracking the same Git remote
Post
Possible drawbacks for having duplicate local sources of the project tracking the same Git remote
Context
I have started working on an Angular upgrade for a medium-sized project (from v. 10 to v. 15) and this is a rather long activity that is interrupted by other changes that need to be performed on the same project.
I have created another branch for the upgrade, but switching back to another branch takes a lot of time (npm install
is very slow and the first npm start
is the same) since branches use different node versions (I am switching these using nvm on Windows).
Possible mitigation
I am thinking of creating a local copy of the project, that tracks the same remote and work separately in the upgrade branch. Doing so requires being more careful (e.g. syncing changes done in the main branch).
Shortly put, I want to avoid making changes to the upgrade branch node_modules
folder (as much as possible) until the upgrade is done.
Are there any other drawbacks to doing the local copy? Or is there any other solution to avoid wasting a lot of time switching back and forth from the upgrade branch?
1 comment thread