Subversion Hosting, Git Hosting and Trac Hosting: Repository Hosting
$6/month flat
Related cards:
Convert a Subversion repository to Git
- To retain all branches you can try the
svn2git
tool. However, this tool has some bugs. - To only import the trunk (with complete history):
git svn clone http://host/svn/...
- Create a [.gitignore](https://makandracards.com/makandra/522-typic...
How to set git user and email per directory
I am using git at several places: at work, at university, and at home. I want an own git user/email for each of those places, but I don't want to care setting the values each time I create or clone a new repository.
Git allows for setting user/em...
Git: Push a new branch and track it immediately
When you create a new branch and push it to origin
, you won't be tracking it. This means a git pull
won't know its remote version.
You could use difficult commands to set up a branch's tracking but it's easier to just push it like this:
...
Duplicate a git repository with all branches and tags
In order to clone a git repository including all branches and tags you need to use two parameters when cloning the old and pushing to the new repository respectively:
git clone --bare http://example.com/old-repo.git
cd old-repo
git pu...
How to push to Git without running CI on GitLab CI, GitHub Actions, or Travis CI
If a project ist configured to spawn CI runners for tests or deployment when pushing to the Repo, a habit of pushing WIP commits regularly may conflict with that.
Here are two solutions that allow you to keep pushing whenever you feel like it.
#...
Shell script to generate a Git commit with Pivotal Tracker story ID and title
We usually generate our commit messages from Pivotal Tracker IDs and titles, like
[#15775609] Index view for conflicts
The geordi command commit
automates this. (See: [Pretty Commit messages via geord...
Configuring Git with .gitconfig
Basic configuration
Please keep this config simple. It should be a starting point for new developers learning Git.
[user]
name = Your Name
email = your.name@domain.com
[branch]
sort = -committerdate
[color]
ui = auto
[color "bra...
Bookmarklet to generate a commit message with Pivotal Tracker story ID and title
For clarity and traceability, your commit messages should include the ID and title of the Pivotal Tracker story you're working on. For example:
[#12345] Add Google Maps to user profiles
Optional further commit messages in the body
Al...
Git: How to create and apply patches
You can convert git commits into patch files. Those can be used to apply to a different repository [1] or by someone else (e.g. sent when sent to them via e-mail).
Creating a patch
- Make your changes and commit them.
- Run ...
Git: Keep your repository tidy
When you're using feature branches, they will stack up if you don't delete them after the merge to master
. Here's how to tidy them up.
Delete feature branches
Find already-merged branches by running
# On branch mast...