-1

I am new at using Git and GitHub and I keep getting this error

fatal: could not create work tree dir 'hello': Permission denied

That's the message I get when I use git clone on my windows terminal. I also tried it on the Git Bash terminal and I still get the same error.

qTips
  • 13
  • 1
  • 7
  • 3
    Does this answer your question? [fatal: could not create work tree dir 'kivy'](https://stackoverflow.com/questions/16376035/fatal-could-not-create-work-tree-dir-kivy) – Super Jade Jul 30 '20 at 04:29

2 Answers2

0

Your terminal probably doesn't have the right permissions. Did you try opening the terminal as administrator?

ciurca
  • 13
  • 1
  • 4
  • how do I do that? Sorry am new at using the terminal – qTips Jul 30 '20 at 04:28
  • right-click on the terminal and you should see a 'Run as Administrator' button. Just as you see in [this](https://external-content.duckduckgo.com/iu/?u=https%3A%2F%2Fwinaero.com%2Fblog%2Fwp-content%2Fuploads%2F2014%2F12%2FWindows-10-Run-as-administrator2.png&f=1&nofb=1) image. – ciurca Jul 30 '20 at 04:31
  • ok I think that might work, am going to give it a try. Is there a way to always open the terminal as an admin? – qTips Jul 30 '20 at 04:35
  • [This](https://www.cnet.com/how-to/always-run-a-program-in-administrator-mode-in-windows-10/) tutorial should do the trick. – ciurca Jul 30 '20 at 04:36
  • @ciurca this is probably better suited as a comment instead of an answer. Avoid one line answers that ask questions within them... instead use comments for that – Sabito stands with Ukraine Jul 30 '20 at 04:40
0
  1. First create a central (remote) repository in GitHub. Git recommends that for every project you need to maintain a unique repository. I.e one repository for one project.

  2. Next create local repository in the local machine. Open GitBash at the required directory and type git init. (If you have to create a new folder please do so.).

  3. After we create our local repository it is very important to link/ sync them. Otherwise how would you know which repository to push into or which remote repository to pull from. Run the following command in the git bash git remote add origin <LinkFromRemoteRepo>.

j4jada
  • 334
  • 1
  • 9