我有一个通过 GitPython 库创建的存储库,其中有一些未提交的更改。我想 stash 这些更改。我该怎么做?
在 GitPython 中搜索“stash”docs没有返回任何结果。
最佳答案
根据文档,"Using git directly" :
In case you are missing functionality as it has not been wrapped, you may conveniently use the git command directly. It is owned by each repository instance.
因此,您可以调用 git stash save
repo.git.stash('save')
关于python - GitPython——如何对 GitPython 存储库进行 'git stash' 更改?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28265396/