title: fatal: Not a git repository - Error
body: <p>I am new to git. I am just using it for version control onto my local machine. I have initialized my git repo by <code>git init</code>. I have manually added some of the folders that I need to by <code>git add "folder name"</code>. There is one particular folder which I am not able to add by using the same command. It is included in the same directory as the others. But I keep getting <code>fatal: Not a git repository "some path"</code>.  I don't understand what the problem is.</p>
  
  <h1>Adding Output</h1>
  
  <pre><code>root@CTO:/home/kougaikw/test# git --version
  git version 1.8.3.2
  
  root@CTO:/home/kougaikw/test# git status
  # On branch master
  #
  # Initial commit
  #
  # Changes to be committed:
  #   (use "git rm --cached &lt;file&gt;..." to unstage)
  #
  #       new file:   main.html
  #
  # Untracked files:
  #   (use "git add &lt;file&gt;..." to include in what will be committed)
  #
  #       .DS_Store
  #       css/
  #       fonts/
  #       images/
  #       instance-config.json
  
  
  root@CTO:/home/kougaikw/test# ls -l
  total 36
  drwxr-xr-x  2 root root 4096 Apr  5 17:04 css
  drwxr-xr-x  2 root root 4096 Apr  5 17:04 fonts
  drwxr-xr-x  5 root root 4096 Apr  5 17:04 images
  -rw-r--r--  1 root root 1004 Mar 13 08:25 instance-config.json
  drwxr-xr-x 10 root root 4096 Apr  5 17:05 js
  -rw-r--r--  1 root root  695 Jan  7 08:50 main.html
  drwxr-xr-x  8 root root 4096 Apr  5 17:06 mocks
  drwxr-xr-x 13 root root 4096 Apr  5 17:07 plugins
  drwxr-xr-x 14 root root 4096 Apr  5 17:07 templates
  
  root@CTO:/home/kougaikw/test# git add js
  fatal: Not a git repository: js/libs/testfolder/../../../../.git/testfolder/html/js/libs/modules
  </code></pre>
  
  <h1>solution</h1>
  
  <p>I had a folder called ".git" inside the directory js/libs/testfolder. Removed it and works fine</p>