97

I am trying to follow this railscast tutorial for authlogic - and it points to the source here -

I have git installed - how do I replicate the source onto my localhost so that I can follow the tutorial like in the screencast?

Mithical
  • 603
  • 1
  • 17
  • 28
RedNax
  • 1,507
  • 1
  • 10
  • 20

4 Answers4

143
git clone git://github.com/ryanb/railscasts-episodes.git
Thilo
  • 257,207
  • 101
  • 511
  • 656
  • 4
    If you want to clone a particular branch instead: `git clone git://github.com/ryanb/railscasts-episodes.git -b branch_name` – ShreevatsaR Dec 23 '13 at 22:13
  • 23
    strange that there are dozens of obscure icons and links and options on GitHub but not a single bit explaining how to do a clone – Kirby Mar 06 '14 at 17:13
  • Your one-liner command works smoothly with [core git](http://msysgit.github.io/) whereas [Git Extensions](http://sourceforge.net/projects/gitextensions/) can't seem to manage authentication (as described [here](http://stackoverflow.com/q/6138493/1864054) & [here](http://stackoverflow.com/q/15584516/1864054)). – Withheld Aug 19 '14 at 20:40
23

To clone a repository and place it in a specified directory use "git clone [url] [directory]". For example

git clone https://github.com/ryanb/railscasts-episodes.git Rails

will create a directory named "Rails" and place it in the new directory. Click here for more information.

bstrong
  • 680
  • 9
  • 20
3

You clone a repository with git clone [url]. Like so,

$ git clone https://github.com/libgit2/libgit2
Kent Aguilar
  • 5,048
  • 1
  • 33
  • 20
0

I use @Thiho answer but i get this error:

'git' is not recognized as an internal or external command

For solving that i use this steps:

I add the following paths to PATH:

  • C:\Program Files\Git\bin\

  • C:\Program Files\Git\cmd\

In windows 7:

  1. Right-click "Computer" on the Desktop or Start Menu.
  2. Select "Properties".
  3. On the very far left, click the "Advanced system settings" link.
  4. Click the "Environment Variables" button at the bottom.
  5. Double-click the "Path" entry under "System variables".
  6. At the end of "Variable value", insert a ; if there is not already one, and then C:\Program Files\Git\bin\;C:\Program Files\Git\cmd. Do not put a space between ; and the entry.

Finally close and re-open your console.

Saeed
  • 3,294
  • 5
  • 35
  • 52