Reputation: 7753
From Wikipedia:
Where is said "Local repository" located physically (in the file system)?
Upvotes: 47
Views: 91105
Reputation: 1
Uttams-MBP:project uttamgc$ ls -al
drwxr-xr-x 9 uttamgc staff 288 Sep 28 14:19 .git
In the example above, project is the folder or directory [mkdir] once this folder is created I move into project directory [cd project] then I git init from the folder and create .git subdirectory. [the third row with .git is the local repository]
Upvotes: 0
Reputation: 17
Working Directory is where your code resides on local machine. Git Local repo is .git/ which is generally inside the Working Directory. It contains HEAD and various useful info. You can have a look of what it contains:
cd .git
ls -a
Upvotes: 1
Reputation: 1203
Working directory is your code directory
Local repository is .git folder in Working directory
Remote repository is bare repository on server or in the filesystem
Upvotes: 7
Reputation: 1581
.git is a place where local repository is stored (not the working directory!)
Working directory usually is a directory where the .git directory is placed
Upvotes: 4
Reputation: 994947
The Working Directory is wherever your files are on your local machine. The Local Repository is the .git/
subdirectory inside the Working Directory. The Index is a conceptual place that also physically resides in the .git/
subdirectory.
Upvotes: 49