title: Clone only the .git directory of a git repo
body: <p>I have a repo in sync with google Drive, but I had the .git directory ignored so it is now uploaded to Google Drive. </p>
  
  <p>Recently I formatted my <code>Gentoo</code> machine and after I had all Google Drive files synced again I realized the <code>.git</code> directory was not there. </p>
  
  <p>The problem is I do not remember if I had some unstagged/uncommited changes in local not pushed to github. </p>
  
  <p>I have been searching but I only found answers for the opposite question (Cloning without the <code>.git</code> directory)</p>
  
  <ul>
  <li><a href="https://stackoverflow.com/questions/600079/how-do-i-clone-a-subdirectory-only-of-a-git-repository">How do I clone a subdirectory only of a Git repository?</a></li>
  <li><a href="https://stackoverflow.com/questions/11834386/cloning-only-a-subdirectory-with-git">Cloning only a subdirectory with git</a></li>
  <li><a href="https://askubuntu.com/questions/460885/how-to-clone-git-repository-only-some-directories">How to clone git repository only some directories?</a></li>
  <li><a href="https://unix.stackexchange.com/questions/233327/is-it-possible-to-clone-only-part-of-a-git-project">Is it possible to clone only part of a git project?</a></li>
  <li><a href="https://stackoverflow.com/questions/3946538/git-clone-just-the-files-please">Git Clone: Just the files, please?</a></li>
  <li><a href="https://stackoverflow.com/questions/11497457/git-clone-without-git-directory">Git clone without .git directory</a></li>
  </ul>
  
  <p>I do not want to make a <code>git clone</code> of my repo until I am sure that possible local changes are not going to be loss.</p>
  
  <p>Is there any way of cloning only the <code>.git</code> folder and then push any local changes that I may have in my machine?</p>