使用Python的本地文件系统(Windows)进行版本控制

时间:2022-05-20 06:29:21

I write some scripts in Python with PyScripter and want to be able to created versions of my .py files without creating copies of the files on disk and managing them manually.

我用PyScripter用Python编写了一些脚本,希望能够创建我的.py文件版本,而无需在磁盘上创建文件副本并手动管理它们。

I know that there are some software used for that such GIT, SVN and some others. I have never used any version control software before. I don't have access to any server-based solution and want to be able to do this just on my local machine. It can be rather simple piece of software with no advanced functionality. Switching between different versions of code is a must, but it would be nice having a tool for finding differences in the code since last commit and alike.

我知道有一些软件用于这样的GIT,SVN和其他一些软件。我之前从未使用过任何版本控制软件。我无法访问任何基于服务器的解决方案,并希望能够在我的本地计算机上执行此操作。它可以是相当简单的软件,没有高级功能。在不同版本的代码之间切换是必须的,但是如果能够找到自上次提交以来类似的代码差异,那将是很好的。

I have access to Microsoft TFS though, but I was not able to find any way to connect PyScripter to TFS. I may consider using another Python IDE if there is comprehensive support for such a version control software I described above.

我可以访问Microsoft TFS,但我无法找到任何方法将PyScripter连接到TFS。如果我对上面描述的这种版本控制软件有全面的支持,我可以考虑使用另一个Python IDE。

1 个解决方案

#1


2  

I would strongly recommend using mercurial - it is easier to get the hang of than git and is itself written in python.

我强烈建议使用mercurial - 它比git更容易获取,它本身是用python编写的。

There are also both a GUI, TortoiseHg, and a web server, (hg serve or start from thg), with the web interface built in.

还有一个GUI,TortoiseHg和一个Web服务器(hg服务或从thg开始),内置Web界面。

#1


2  

I would strongly recommend using mercurial - it is easier to get the hang of than git and is itself written in python.

我强烈建议使用mercurial - 它比git更容易获取,它本身是用python编写的。

There are also both a GUI, TortoiseHg, and a web server, (hg serve or start from thg), with the web interface built in.

还有一个GUI,TortoiseHg和一个Web服务器(hg服务或从thg开始),内置Web界面。