How do I set up so that I can have two identical repos except one doesn’t have the source code? Just the production build. I want to update the one with the source code continually and then once I feel like making a new build, update the prod repo. What’s the best workflow for this? In layman’s terms for a beginner.
Hi shacp! You don’t want the prod repo to have any source code at all, just the compiled binaries?
You could create a totally separate repo that just contains a README and use that for your prod repo, and attach each build as a Release?
Doing this seems perhaps a little counterproductive - traditionally Releases are a snapshot of the code in the repository at a specific point.
You wouldn’t perhaps prefer to have a dev repo where you work on your code as normal, and then a prod repo where you push up only the
master branch when you are ready to make a new production build? You could do that by creating multiple remotes from your local copy:
So then you could use:
git remote add origin <DEV_REPO_URL>
…and push to origin when working on your code most of the time. And then add:
git remote add prod <PROD_REPO_URL>
…and only occasionally push to prod. (And then make a release as well, if you like.)
I’d like to hear what other people think of adding Releases to a repo that doesn’t contain the code. Is it an absolute no no, or an acceptable practice?