You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I would find a function that filters for commits that have been pushed to a remote repository useful in revsets.
Proposed function description: pushed(x): all commits in x that have been pushed to a remote repo
Example usages:
Lint all commits in the current stack that haven't been pushed yet (commits that have been pushed shouldn't be modified!):
`$ git test fix --exec 'cargo fmt --all' 'stack() - pushed(stack())'
Print all new commits that will be pushed with 'git push':
$ git_push_check() { echo "New commits that will be pushed:" && git query "master..$1 - pushed(master..$1)" ; }
The text was updated successfully, but these errors were encountered:
It might actually be easier or more composeable to define pushed(), which evaluates to all commits reachable from a remote ref. (The implementation treats commit ranges symbolically and has separate evaluate vs contains code paths, so it can be made efficient in many cases.)
arxanas
changed the title
[Feature Request] Add a 'pushed(x)' built-in function to revsets
Add a 'pushed(x)' built-in function to revsets
Oct 10, 2024
I would find a function that filters for commits that have been pushed to a remote repository useful in revsets.
Proposed function description:
pushed(x)
: all commits in x that have been pushed to a remote repoExample usages:
Lint all commits in the current stack that haven't been pushed yet (commits that have been pushed shouldn't be modified!):
`$ git test fix --exec 'cargo fmt --all' 'stack() - pushed(stack())'
Print all new commits that will be pushed with 'git push':
$ git_push_check() { echo "New commits that will be pushed:" && git query "master..$1 - pushed(master..$1)" ; }
The text was updated successfully, but these errors were encountered: