If the base branch for your repository is not the default master, you might have encountered this bizarre Pull Request problem when you try to deploy from base branch onto master:
Tag Archives: Git
Git Submodule Life-Saving Setup
What’s the use of git submodules? It’s mostly useful when you want to work on the code in both the main repo and the sub repo at the same time. Otherwise, a normal dependency management system would suffice.
To have submodules safely set up so that you run into walls less often, do the following:
Continue readingHow to Auto-Deploy to Server on Git Push
Goal:
- If
git pushonmasterbranch - Then sync files onto server and deploy (e.g., running
yarn run buildor any other scripts)
I’m on DigitalOcean’s server, but this works on any self hosted servers.
Continue readingReference: How to Git Stash
To save the uncommitted changes:
# Either without a name $ git stash # Or with a stash name: $ git stash save funny-stash
DigitalOcean: How To Create A Rails App with Git Auto Deploy
What we want to achieve:
- one click create a working version of rails project on DigitalOcean
- set up a local working version of the project
- set up remote & local git repo so we could push to update remote rails project folder
- and deploy automatically with push
Git: “git push” Pushed to A Different Remote Branch Than The One It’s Tracking Remotely?
git branch -vv shows that my local develop branch is tracking the remote fix/some-bug branch. However, a git push command pushed my commits to the remote develop branch.
WTF?
Why Sometimes Git Ignore Doesn’t Work
Sometimes the files you’re trying to ignore had already been submitted into version control on previous occasions. To ignore those existing files, you’ll need to re-submit them as deleted files. After which they would be removed from the repository. It looks like .gitignore isn’t working, but it actually is.