Welcome Guest, Not a member yet? Register   Sign In
Pushing only certain code to different repositories
#1

I have a Codeigniter project that needs two different repos: one for local development with my team (bitbucket) and one on my client's side for deployment (gitlab). I am looking for ways to simplify getting changes from one repo to the other.

My issue: For local development, I need files which I don't want to push to the clients server (composer, package.json, ...) and vice versa (deploy.php, yml files from gitlab-ci), but the majority of the files is the same and only changed by me and my team.

From what I have read, simply adding a second git-remote wouldn't work because I couldn't have two gitignore files. I have never worked with git submodules, but from what I understand, it would require subfolders and the files that differ between the repos need to be in the root directory. Have I understood this correctly?

Is there a way to push only certain files in certain directions/remote repos?
Reply


Messages In This Thread
Pushing only certain code to different repositories - by DennisSSebasiStephen - 07-08-2022, 01:18 AM



Theme © iAndrew 2016 - Forum software by © MyBB