-
Notifications
You must be signed in to change notification settings - Fork 395
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
revset: Implement 'oldest' function that complements the 'latest' function in the revset language #5565
base: main
Are you sure you want to change the base?
revset: Implement 'oldest' function that complements the 'latest' function in the revset language #5565
Conversation
feec2bf
to
fab8fa3
Compare
Hello, welcome to the project. This can be all one commit and should be titled something like |
nit: it seems like it should be |
Yeah, it makes sense! I'll go with |
I like the rename to |
fab8fa3
to
6400d1d
Compare
Ah, I just renamed the references in this PR to earliest() 😅 That's okay I can revert this commit. @emilazy I reckon the renaming from cc: @martinvonz |
6400d1d
to
29d945c
Compare
Yeah not trying to hold up this PR, just saying that I think renaming them both actually seems like a good idea in general. We’d want to keep a backwards compatibility alias etc. for a while. |
cb13a8b
to
ca3df73
Compare
ca3df73
to
ebec07f
Compare
Sorry, it is the commit message which should contain |
fwiw, |
This PR implements a new function
oldest(x[, count])
that returns the oldest count commits in x, based on committer timestamp and the default count is 1. This is an exact complementary function tolatest()
available in the revset language.Here are a few use cases that I could think about
oldest(author(martinvonz), 5)
returns the oldest 5 commits from the authormartinvonz
.oldest(all(), 5)
returns the oldest 5 commits in this repository.Checklist
If applicable:
CHANGELOG.md