-
-
Notifications
You must be signed in to change notification settings - Fork 659
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
Resolves #270: add support for --time-style=relative #1061
Conversation
You can check the Testing with vagrant section of the README, and the README in the xtests folder. You can probably extend these date tests (tip: use e.g. |
Thanks for the hint! Somehow I missed that part. Will add tests |
How are relative future dates printed? (edit: changed underscores to Xs) |
@ariasuni I added tests as described. Many other tests were failing on my machine, is that intended? |
Currently it would print just now, also since |
I would personally consider sind more an edge case that shouldn't normally happen. printing |
Note that If something is amiss in |
Note that |
This probably boils down to a design decision:
|
It may make sense to provide both options depending on listing options. Terse, but less user-friendly look may be poor default mode. |
Uh yeah since they’re not on the CI, there are some that got broken and I need to merge the fixes and stuff… if your tests work then it’s fine. Also, it would be nice to have a test for future dates, see there: exa/xtests/details-view-dates.toml Lines 28 to 36 in dceca33
|
done, added the far future test. |
@ariasuni is there anything else missing? I'm happy to change where necessary :) |
just went through old open PRs and came back to this one :) @ariasuni I would love to see this in exa, I'm happy to add anything that's needed to get this finished up |
d53dc7a
to
32b2c5b
Compare
Hello @ariasuni I just remembered that I still had this PR open, and would love to see this feature in To start, I just rebased on the current master :) |
This would be great to have. |
Closing this, since exa is unmaintained (see #1243), and this has been done in the active fork eza. Thanks! |
This adds showing relative timestamps for #270 .
For the first version this uses
timeago
from the issue.I didn't find tests covering this part of the codebase, I'm happy to add them with a better idea on what should be covered and how.
Also I'm happy to change the format if that's something we want (the LS++ format also looks neat).
Different colouring for different ages I would add separately.