-
Notifications
You must be signed in to change notification settings - Fork 47
Add support for SRC vcs #245
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
src/diffuse/vcs/src.py
Outdated
if rev is None: | ||
return 'BASE' | ||
m = int(rev) | ||
return str(max(m > 1, 0)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This appears to have the same error as the SVN code has. I reported it in #227.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmmm - I had this in my 2018 version (not public, probably derived from the sourceforge code):
+ if m > 1:
+ return str(m - 1)
but I bowed to the svn version when I ported that old cruft to 0.9.0
That said, I think this is only used in conflict resolution which is kinda moot in the way I use SRC (single-user). Probably should be corrected. I wonder why #227 was not fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not conflict resolution, it's for getting the previous revision of the passed argument.
Does this mean that you didn't test all the options?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The only use-cases that make sense for src are:
# diffuse -r <rev> <file>
# diffuse -c <rev> <file> ie a single file
# diffuse -m [ <file> ]
... those work in my testing.
Unfortunately, diffuse has bug #246 which obviates "diffuse -r v1 -r v2 " in src as well as git.
I have updated getPrevRevision as suggested. Thanks.
Simple-minded support for SRC, the simple-minded vcs