[英]Version control on Dropbox vs git
I have a LaTeX manuscript which I am preparing with my group and are using a shared Dropbox folder. 我有一个LaTeX手稿,我正在准备我的小组,并使用共享的Dropbox文件夹。 Technically this is version-controlled, but I would like to be able to see diffs of changes you get with a git repository. 从技术上讲,这是版本控制的,但我希望能够看到使用git存储库获得的更改差异。
Is it possible to create a local git repository to commit to for this reason, without creating a remote repository (since Dropbox kind of serves this purpose already)? 因此可以创建一个本地git存储库来提交,而无需创建远程存储库(因为Dropbox已经为此目的服务)了吗?
I mentioned before that using Dropbox for a git repo isn't safe . 我之前提到使用Dropbox进行git repo并不安全 。
More specifically, the .git/
folder should not be replicated in dropbox. 更具体地说,不应在dropbox中复制.git/
文件夹。
That means you can: 这意味着你可以:
.git
folder outside the folder which will contain your files, 将.git
文件夹移到包含文件的文件夹之外 , GIT_DIR
to the .git/ folder path (again moved elsewhere) 将环境变量GIT_DIR
设置为.git /文件夹路径(再次移动到其他位置) git
inside your document folder as usual. 像往常一样在文档文件夹中使用git
。 .git
) with Dropbox. 使用Dropbox备份相同的文档文件夹(不包括.git
)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.