我在一个名为"Development“的网络驱动器上有一个python文件项目。
我为新特性创建了Development分支,然后在完成后合并回Development。其他人将来也会这样做。
我想把"Development“推到另一个叫做"Production”的单独文件夹中,但我这一生都想不出该怎么做。
有什么建议吗?该怎么做呢?
谢谢。
我在尝试的时候遇到了这个错误。
Pushing to G:\03 GIS RESOURCES\05 GIS PROGRAMMING\Production
remote: error: refusing to update checked out branch: refs/heads/master
remote: error: By default, updating the current branch in a non-bare repository
remote: error: is denied, because it will make the index and work tree inconsistent
remote: error: with what you pushed, and will require 'git reset --hard' to match
remote: error: the work tree to HEAD.
remote: error:
remote: error: You can set 'receive.denyCurrentBranch' configuration variable to
remote: error: 'ignore' or 'warn' in the remote repository to allow pushing into
remote: error: its current branch; however, this is not recommended unless you
remote: error: arranged to update its work tree to match what you pushed in some
remote: error: other way.
remote: error:
remote: error: To squelch this message and still keep the default behaviour, set
remote: error: 'receive.denyCurrentBranch' configuration variable to 'refuse'.
To G:\03 GIS RESOURCES\05 GIS PROGRAMMING\Production
! [remote rejected] master -> master (branch is currently checked out)
error: failed to push some refs to 'G:\03 GIS RESOURCES\05 GIS PROGRAMMING\Production'发布于 2015-09-19 02:24:37
选项A
您可以将Development项目克隆到另一个文件夹中。
简介:
git clone <repository> <directory>示例:
git clone <path/to/Development> Production选项B
将文件夹开发的内容(包括.git文件夹)复制到文件夹生产中。
https://stackoverflow.com/questions/32658445
复制相似问题