version-control

GIT correct workflow for my Branch structure

。_饼干妹妹 提交于 2020-07-10 17:31:38
问题 I started to implement a GIT repository following a specific Workflow. The workflow is the following: v0.1 v0.2 / / releases------------------------------------------------- / | | main--------------------------[0.1]---------------[0.2] \ / \ / development--- / \ / \ / \ / feature-ABC feature-XYZ main contains the latest stable code where any developer can just git checkout -> build -> deploy main contains tags used to identify a release Every release version is branched into release branch

GIT correct workflow for my Branch structure

最后都变了- 提交于 2020-07-10 17:28:29
问题 I started to implement a GIT repository following a specific Workflow. The workflow is the following: v0.1 v0.2 / / releases------------------------------------------------- / | | main--------------------------[0.1]---------------[0.2] \ / \ / development--- / \ / \ / \ / feature-ABC feature-XYZ main contains the latest stable code where any developer can just git checkout -> build -> deploy main contains tags used to identify a release Every release version is branched into release branch

Visual Studio Code - Group pending changes by folder

自作多情 提交于 2020-07-07 05:31:34
问题 I want to get rid of my current IDE (Jetbrains) and migrate to Visual Studio Code because of some supported extensions. There is only one thing I'm missing in VS Code... If I have multiple files in source control as pending changes, they are just shown as a flat list. In e.g. IntelliJ it is possible to group pending changes files by their folder. This is very helpful, because I have multiple files sharing the same filename... Is there an extension, I can install to add this feature or is it

Visual Studio Code - Group pending changes by folder

生来就可爱ヽ(ⅴ<●) 提交于 2020-07-07 05:31:12
问题 I want to get rid of my current IDE (Jetbrains) and migrate to Visual Studio Code because of some supported extensions. There is only one thing I'm missing in VS Code... If I have multiple files in source control as pending changes, they are just shown as a flat list. In e.g. IntelliJ it is possible to group pending changes files by their folder. This is very helpful, because I have multiple files sharing the same filename... Is there an extension, I can install to add this feature or is it

How can I use Git to identify function changes across different revisions of a repository?

折月煮酒 提交于 2020-06-27 13:05:34
问题 I have a repository with a bunch of C files. Given the SHA hashes of two commits, <commit-sha-1> and <commit-sha-2> , I'd like to write a script (probably bash/ruby/python) that detects which functions in the C files in the repository have changed across these two commits. I'm currently looking at the documentation for git log, git commit and git diff. If anyone has done something similar before, could you give me some pointers about where to start or how to proceed. 回答1: That doesn't look

How can I use Git to identify function changes across different revisions of a repository?

百般思念 提交于 2020-06-27 13:05:31
问题 I have a repository with a bunch of C files. Given the SHA hashes of two commits, <commit-sha-1> and <commit-sha-2> , I'd like to write a script (probably bash/ruby/python) that detects which functions in the C files in the repository have changed across these two commits. I'm currently looking at the documentation for git log, git commit and git diff. If anyone has done something similar before, could you give me some pointers about where to start or how to proceed. 回答1: That doesn't look

HG-Git: AttributeError: 'bytes' object has no attribute 'encode'

不羁的心 提交于 2020-06-26 14:08:17
问题 I'm trying to clone a git repository with mercurial and hg-git, but an AttributeError keeps coming up. When I run hg clone git://github.com/michaelfm1211/simpleserve , the output I get is this: destination directory: simpleserve ** unknown exception encountered, please report by visiting ** https://mercurial-scm.org/wiki/BugTracker ** Python 3.8.3 (default, May 31 2020, 07:24:01) [Clang 11.0.3 (clang-1103.0.32.62)] ** Mercurial Distributed SCM (version 5.4.1) ** Extensions loaded: hggit

How to convert a file tracked by git to git-lfs?

江枫思渺然 提交于 2020-06-25 10:23:18
问题 How do I convert a single file (e.g. a png) which is already committed as a regular object to git-lfs? I do not want to migrate the whole repo and I also do not want to rewrite the history of the repo. 回答1: git lfs track will begin tracking a new file or an existing file that is already checked in to your repository. When you run git lfs track and then commit that change, it will update the file, replacing it with the LFS pointer contents. Here I have a repository with a PNG checked in

Keep Git Reflog Indefinitely?

痴心易碎 提交于 2020-06-25 07:40:20
问题 I tend to be a bit paranoid about my data, including the ability to recover it. Git reflog data is pruned after 30 days. Is there a way of setting it so that the reflog data is maintained and kept indefinitely? Any major advantage or disadvantage (other than space or speed considerations) to doing so? 回答1: Caveat: reflogs are local and are not sent/received with push/pull operations. Cons: reflogs may result in (otherwise) unreachable snapshots (and consequently blobs) being kept around,

Git pre-commit hook not running on windows

旧街凉风 提交于 2020-06-24 03:24:09
问题 I'm just starting to look into Git hooks, but I can't seem to get them to run. I set up a local repository, so there is now a '.git' directory in my project folder. I have added a '.cmd' file into the C:/path/to/my/project/.git/hooks directory named 'pre-commit.cmd'. Here is the contents of this file: echo "HOOK RUNNING" echo. 2>C:/path/to/my/project/.git/hooks/EmptyFile.txt This should echo the text "HOOK RUNNING" and create an empty text file in that directory. However, if I commit changes