如何将 Git 存储库克隆到特定文件夹中? - How do you clone a Git repository into a specific folder?

问题:

Executing the command git clone [email protected]:whatever creates a directory in my current folder named whatever , and drops the contents of the Git repository into that folder:执行命令git clone [email protected]:whatever在我命名为当前文件夹中创建一个目录whatever ,并丢弃Git仓库到该文件夹的内容:

/httpdocs/whatever/public

My problem is that I need the contents of the Git repository cloned into my current directory so that they appear in the proper location for the web server:我的问题是我需要将 Git 存储库的内容克隆到我的当前目录中,以便它们出现在 Web 服务器的正确位置:

/httpdocs/public

I know how to move the files after I've cloned the repository, but this seems to break Git, and I'd like to be able to update just by calling git pull .我知道在克隆存储库后如何移动文件,但这似乎破坏了 Git,我希望能够通过调用git pull进行更新。 How can I do this?我怎样才能做到这一点?


解决方案:

参考一: https://en.stackoom.com/question/2jMc参考二: https://stackoom.com/question/2jMc
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章