Repository: huggingface/huggingface_hub

Issue:
Improve error message when push to hub fails because it is not a git repo
**Is your feature request related to a problem? Please describe.**

I can't figure out which folder I need to modify to get a `push_to_hub` to work. I would like to improve the already excellent error message:

```python
/usr/lib/python3.8/site-packages/huggingface_hub/repository.py in clone_from(self, repo_url, token)
    760                 # Check if the folder is the root of a git repository
    761                 if not is_git_repo(self.local_dir):
--> 762                     raise EnvironmentError(
    763                         "Tried to clone a repository in a non-empty folder that isn't a"
    764                         " git repository. If you really want to do this, do it"

OSError: Tried to clone a repository in a non-empty folder that isn't a git repository. If you really want to do this, do it manually:
git init && git remote add origin && git pull origin main
 or clone repo to a new folder and move your existing files there afterwards.
OSError: Tried to clone a repository in a non-empty folder that isn't a git repository. If you really want to do this, do it manually:
git init && git remote add origin && git pull origin main
 or clone repo to a new folder and move your existing files there afterwards.
```

**Describe the solution you'd like**

I would like the `self.local_dir` variable to be interpolated into the error message: 

```
"Tried to clone a repository in a non-empty folder that isn't a"
f" git repository ('{self.local_dir}'). If you really want to do this, do it"
```

**Describe alternatives you've considered**

None

**Additional context**

 None


Discussion:
Happy to implement the suggested fix
Hi @payoto, I'm completely fine with the idea as it would for sure improve user experience. Feel free to implement it and thank you in advance! :)
Out of curiosity, in which context are you using the `Repository` class in your projects ? Question is unrelated to the issue, it's just to get to know more about the usage of this module. 
Great, I'll do that then.

It's used as part of the optimum Graphcore library (the implementation of optimum for Graphcore's IPU). The error shows up during a call to `push_to_hub`. I've been running quite a lot of models and tinkering with moving/sharing caches between containers and I suspect a `.git` folder got lost in the process.

Resolving patch:
diff --git a/src/huggingface_hub/repository.py b/src/huggingface_hub/repository.py
--- a/src/huggingface_hub/repository.py
+++ b/src/huggingface_hub/repository.py
@@ -760,11 +760,12 @@ def clone_from(self, repo_url: str, token: Union[bool, str, None] = None):
                 # Check if the folder is the root of a git repository
                 if not is_git_repo(self.local_dir):
                     raise EnvironmentError(
-                        "Tried to clone a repository in a non-empty folder that isn't a"
-                        " git repository. If you really want to do this, do it"
-                        " manually:\ngit init && git remote add origin && git pull"
-                        " origin main\n or clone repo to a new folder and move your"
-                        " existing files there afterwards."
+                        "Tried to clone a repository in a non-empty folder that isn't"
+                        f" a git repository ('{self.local_dir}'). If you really want to"
+                        f" do this, do it manually:\n cd {self.local_dir} && git init"
+                        " && git remote add origin && git pull origin main\n or clone"
+                        " repo to a new folder and move your existing files there"
+                        " afterwards."
                     )
 
                 if is_local_clone(self.local_dir, repo_url):


Test patch: