spiralofhope logo
spiralofhope logo

S
piral of Hope
Better software is possible.
Styles
Table of Contents

Programming >

See also tig (text-mode interface for git)


Fix the default git push

Cloned something and want to fix its default push?

git remote rm origin 
git remote add origin git://github.com/spiralofhope/shoes.git
.. hrm, not working right, try editing .git/config and changing the url line to something like git@github.com:spiralofhope/random-shoes.git

Tagging

\git tag "v1.3"
\git push --tags
This provides a new package to download.

Download everything fresh

Downloading everything fresh. Maybe after accepting a pull request.

git pull git@github.com:spiralofhope/shoes-contrib.git master

Revisionism

Forgot to check in an old revision of a file

See also [1]

Well there's no easy way. It's probably doable but I can't find a solution.

The closest I get is an incomplete solution here: [2]

Find the commit hash before the file you want to modify, then check it out.

\git checkout COMMIT_HASH
Make your changes, then commit them.

\git commit -a
FIXME ... then supposedly there's a way to propagate the changes back to the master's HEAD. Fucked if I know how. The above link doesn't actually explain that. I am disappoint.

Go back to the present.

\git checkout master