Skip to content

Instantly share code, notes, and snippets.

View rudr4x5h's full-sized avatar
Rolling Magic

Adarsh rudr4x5h

Rolling Magic
  • Bharat (i.e. India)
  • 08:45 (UTC +05:30)
View GitHub Profile
@rudr4x5h
rudr4x5h / gist:b2d6f3806b84ddb8fc7cf7869e79f00d
Created October 20, 2017 09:18 — forked from CristinaSolana/gist:1885435
Keeping a fork up to date

1. Clone your fork:

git clone git@github.com:YOUR-USERNAME/YOUR-FORKED-REPO.git

2. Add remote from original repository in your forked repository:

cd into/cloned/fork-repo
git remote add upstream git://github.com/ORIGINAL-DEV-USERNAME/REPO-YOU-FORKED-FROM.git
git fetch upstream

How-to setup a simple git push deployment

These are my notes basically. At first i created this gist just as a reminder for myself. But feel free to use this for your project as a starting point. If you have questions you can find me on twitter @thomasf

On the server (example.com)

  1. Create a user on example.com, as which we (the git client) connect (push) to exmaple.com.
sudo useradd -m -s /usr/bin/git-shell git