The command
hg outgoing
compares the local repo to the default push location; it accesses the push location to do it.
I'd like to ask the question "have I checked in changes in my local repo since my last hg push
?" without having to access the remote repo.
It seems like there might be enough info in the local repo to figure that out; if so, is there a command to determine that?
There isn't a built-in way to do it. Tracking what has been pushed would be slightly tricky because you can push to multiple places. And you can pull from multiple places. So I could push to X then push to Y then pull from Z and my 'hg outgoing X' output is difficult to predict local-only.
That said you could use a command like this:
hg tag --local --force -r tip pushed
That creates a local-only tag pointing to the current tip. If you always run that after pushing you'll always know what was last pushed.
You could create a post-push hook to do that in your .hgrc:
[hook]
post-push = hg tag --local --force -r tip pushed
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With