[Gambas-user] A little change for the IDE Version Control (git) popup
Me
adamnt42 at gmail.com
Thu Sep 13 07:16:55 CEST 2018
The following seems to work as far as I can see. It adds a "Status" line to the Project Properties popup Version control tab
and just shows whther the current git branch is up to date or not. It goes at the end of CVersionControlGit.Info method just
above the Return cInfo line at the end of the method. It does no harm AFAICS and I find it quite handy. It may need transaltion.
Sorry I can't produce a patch for it. I am still not really on top of this git stuff. So here's the actual source:
aResult = Split(VersionControl.Shell("cd " & Shell(Project.Dir) & "&& git status -s"), "\n")
If aResult.Count > 0 Then
cInfo[("Status")] = (aResult.Count - 1) & " uncommitted changes: " & Trim(aResult.Join("; "))
Else
cInfo[("Status")] = "Up to date"
Endif
Hope you find it worthwhile and include it in the base code sometime.
b
--
Me <adamnt42 at gmail.com>
More information about the User
mailing list