Describe the problem/challenge you have
We use vendir in meta-projects, and work directly in the git/hg synced sub-repositories.
After doing some changes in them, we cannot do a "vendir sync" without loosing local changes (and lazy doesn't work if we pull some ref changes).
Also, after commit & pushing changes in the sub-repositories, we would like to automatically update the vendir configuration file with the current commit id/tag of each repo.
Describe the solution you'd like
We think vendir could benefit from a "dev" mode, which would be enabled by using a "dev-sync" command or a "--dev" switch on the sync command.
When turned on, vendir would change its sync behavior for mercurial and git (at least) in the following way:
- if the target directory already exists, keep it
- when using already existing target :
- check if non-committed changes exists, in which case the sync is aborted
- fetch & checkout directly in the target directory
A new command "dev-baseline" (for example) would, for each vcs directory, determine what the current ref is:
- if current revision has a tag, the tag
- otherwise, the sha of the current revision
If the ref in the vendir file is not a branch (or a topic the mercurial case), and does not match the current ref determined above, the configuration is updated with the new current ref.
Anything else you would like to add:
The overall experience is inspired by the "hg-confman" mercurial extension that we intend to replace with vendir.
We are willing to work on an implementation for these features, and would like your opinion before diving into coding.
Describe the problem/challenge you have
We use vendir in meta-projects, and work directly in the git/hg synced sub-repositories.
After doing some changes in them, we cannot do a "vendir sync" without loosing local changes (and lazy doesn't work if we pull some ref changes).
Also, after commit & pushing changes in the sub-repositories, we would like to automatically update the vendir configuration file with the current commit id/tag of each repo.
Describe the solution you'd like
We think vendir could benefit from a "dev" mode, which would be enabled by using a "dev-sync" command or a "--dev" switch on the sync command.
When turned on, vendir would change its sync behavior for mercurial and git (at least) in the following way:
A new command "dev-baseline" (for example) would, for each vcs directory, determine what the current ref is:
If the ref in the vendir file is not a branch (or a topic the mercurial case), and does not match the current ref determined above, the configuration is updated with the new current ref.
Anything else you would like to add:
The overall experience is inspired by the "hg-confman" mercurial extension that we intend to replace with vendir.
We are willing to work on an implementation for these features, and would like your opinion before diving into coding.