dirk-thomas / vcstool

Vcstool is a command line tool designed to make working with multiple repositories easier
Apache License 2.0
398 stars 86 forks source link

BUG: VCS status does not indicate problems if a tag was force-pushed #275

Open Ryanf55 opened 1 month ago

Ryanf55 commented 1 month ago

Problem

I have a repository I use. The authors created a tag v1.2.3 on commit A. Then, they deleted the tag and re-tagged, this time on a new commit B. vcs status indicates the repository is on v1.2.3, but it's actually on commit A. v1.2.3 actually points to B.

Expected behavior

vcs pull src then vcs status shall show I am on commit B rather than the tag.

Actual behavior

VCS lets me be on the wrong commit with no warnings or errors, it's silently the wrong commit.

andry81 commented 1 month ago

@Ryanf55 As a suggestion I advise to keep use or add the .gitmodules + GitExtensions. It tracks things like that and shows desync-ed modules. But as a disadvantage you have to convert and commit changes from vcstool file into the .gitmodules file.

Ryanf55 commented 1 month ago

We migrated off of gitmodules because of all the issues of desync, and the fact that we have a rolling HEAD for most of the 20 repositories to save time. We also develop in Linux, which it looks like GitExtensions is Microsoft specific.

andry81 commented 1 month ago

We migrated off of gitmodules because of all the issues of desync, and the fact that we have a rolling HEAD for most of the 20 repositories to save time. We also develop in Linux, which it looks like GitExtensions is Microsoft specific.

And nevertheless you don't have to use .gitmodules for the checkout. You can keep checkout through the vcstool and track changes through the GitExtensions which tracks the .gitmodules status.

andry81 commented 1 month ago

We also develop in Linux, which it looks like GitExtensions is Microsoft specific.

https://github.com/gitextensions/gitextensions/wiki/How-To:-run-Git-Extensions-on-Linux