Github & Markdown

How to setup a Github repository and push content


Github interface:

  • Connect to your Github account an chose “Create new repository” on the top right panel.
  • Give it a name & description and save.

Back to your desktop, install Git and enter your Id and mail.

$ apt-get install git
$ git config --global "your account name"
$ git config --global "account email"

Create a folder for your work, code, pages, whatever. Open a terminal and initialize your folder with:

$ git init
$ vim

This will create the project’s markdown readme file. Markdown is a rich and easy formatting syntax. This readme will be displayed on your Github repo page to explain your project.

Connect the local folder to your Github repo :

$ git remote add origin

Configuration is over. Learn the 3 basic Git rules to send data:

  1. List the files to be sent on your repo
  2. Commit your files with the appropriate message
  3. Send files
 $ git add filename # specify a single file
 $ git add -u       # select all, including deletions
 $ git commit -m 'message'
 $ git push origin master

Pull content from repositories

Create your local folder, initialize it:

$ mkdir SomeoneProject
$ cd SomeoneProject/
$ git init

Pull the project’s files in your local folder:

$ git pull

Play with it.


A quick historic reminder first ?

The Markdown language was created in 2004 by John Gruber with substantial contributions from Aaron Swartz,with the goal of allowing people “to write using an easy-to-read, easy-to-write plain text format, and optionally convert it to structurally valid XHTML (or HTML)”.

All you want to know will be on John Gruber’s webpage : philosophy, basics and syntax.

  • On Linux, Vim will automatically detect & colorize .md extension files
  •  Gedit has an excellent markdown plugin, with HTML live preview.




Comments are closed.

Blog at

Up ↑