Commit Graph

179 Commits

Author SHA1 Message Date
Benjamin Sago
1f167dda41
Merge pull request #577 from 0rvar/feature/suppress-columns
Add support for suppressing table columns
2020-01-19 00:41:27 +00:00
Benjamin Sago
8ccff86940
Merge pull request #450 from Bond-009/2018
Update to Rust 2018
2020-01-18 23:23:43 +00:00
Benjamin Sago
44664bf757
Merge pull request #289 from mqudsi/optional_args
Optional args support
2020-01-18 23:22:17 +00:00
Orvar Segerström
250104c9da Add new suppress flags to --help 2019-12-23 12:08:03 +01:00
Orvar Segerström
925f5173c1 Add support for suppressing table columns 2019-08-29 14:34:30 +02:00
Bond_009
f599c7ce93 Update to Rust 2018 2019-07-19 20:40:21 +02:00
Oleksii Filonenko
58c821be6e
Add documentation for --icons flag
- Update completions
  - fish
  - zsh
- Update man page
- Update help text
2019-07-19 09:58:50 +03:00
Benjamin Sago
9497b30b33 Merge branch 'glyphs' of https://github.com/asoderman/exa into asoderman-glyphs
# Conflicts:
#	src/options/flags.rs
#	src/options/view.rs
#	src/output/grid.rs
2019-07-15 03:54:31 +01:00
Benjamin Sago
9e1200f9b7 Fix failing tests 2019-07-15 03:37:05 +01:00
Benjamin Sago
faed8f9b82
Merge pull request #457 from ariasuni/fix-sorting-by-created-time
Fix sorting by created time
2019-07-15 03:30:52 +01:00
Benjamin Sago
df9b32c892 Fix a couple warnings 2019-07-13 21:17:48 +01:00
ariasuni
f0e7321506 Fix and add tests 2019-03-23 17:23:43 +01:00
ariasuni
39a49a3d36 Check if the sort field is supported by the OS 2019-03-23 17:23:43 +01:00
ariasuni
56717c7336 Add “changed” sort option, to replace old incorrect “created” 2019-03-23 17:23:40 +01:00
ariasuni
80b0d9dd0d Display if a file is ignored by git 2018-11-20 18:12:38 +01:00
James Reed
7218fb4b6a
Document only-dirs option 2018-10-26 17:21:31 -06:00
James Reed
89a6e14e15
Move level option to correct group 2018-10-26 17:15:48 -06:00
Benjamin Sago
c2bb986618 Replace Default impls that use state with fns
The Default impls for DefaultFormat and LoadFormat were originally called ‘new’, to which Clippy suggested that they be changed. But as these functions change based on what the year is, a function called something other than ‘new’, like ‘load’.
2018-10-13 22:15:10 +01:00
Benjamin Sago
ecc4138d56 Merge branch 'clippy_fixes' of https://github.com/thibran/exa into thibran-clippy_fixes
# Conflicts:
#	src/options/view.rs
#	src/style/lsc.rs
2018-10-13 22:07:35 +01:00
Benjamin Sago
a4d9b5314f
Merge pull request #405 from Don42/feature_only_dirs
Flag for only showing directories
2018-09-27 21:01:15 +01:00
Marco 'don' Kaulea
33167a2282 Add short option for only-dirs 2018-07-13 17:38:36 +02:00
Marco 'don' Kaulea
054cac6b82 Add option to only display directories
This allows printing directory trees without any files, only
showing the structure.
I haven't decided on a letter for the short option.

Implements #401
2018-07-12 18:51:14 +02:00
Thibaut Brandscheid
755876e9b6 fix most clippy warnings 2018-06-19 17:17:39 +02:00
mopp
991781070e refers TIME_STYLE environment variable if it exists and the argument is not given 2018-06-15 04:38:32 +09:00
Benjamin Sago
55048f7ee2
Merge pull request #380 from kornelski/master
Replaced try!() with ?
2018-05-28 10:50:06 +02:00
Benjamin Sago
5438f949c9
Merge pull request #311 from martinlindhe/master
adjust some spelling
2018-05-28 10:47:38 +02:00
Kornel
2976b487ab Replaced try!() with ? 2018-04-18 01:16:32 +01:00
Alex Soderman
68954f9142 Added --icons for oneline mode 2018-04-01 19:00:27 -04:00
Alex Soderman
5991bd4ab7 Added icons for --long view 2018-04-01 18:28:31 -04:00
Alex Soderman
217d1eefa9 moved icons functionality to grid mode 2018-03-26 17:02:05 -04:00
Alex Soderman
57e8802977 Added icons mode w/ prepending (icons themselves do not appear yet) 2018-03-22 19:13:02 -04:00
Alex Soderman
67f2fcc748 Added --icons flag 2018-03-20 22:30:41 -04:00
BenWhitehead
a156d96768 Add new sort option .name and .Name
Add two new sort options `.name` and `.Name` which with ignore a leading
`.` if present on the file name before sorting according to `name` and
`Name`.

This new sort is convenient if you want to list hidden and unhidden
files sorted together.
2018-01-30 15:01:56 -08:00
Martin Lindhe
7b1ee01eb5 adjust some spelling 2017-10-31 06:24:31 +01:00
Benjamin Sago
c7497f3778 Display more information for non-release releases 2017-10-08 20:09:46 +01:00
Benjamin Sago
e154b58268 Move EXA_DEBUG variable to vars file 2017-10-08 17:24:50 +01:00
Benjamin Sago
59d9e90f20 Replace “mi” colour with “bO” overlay
Fixes #288, but more-or-less as a side-effect.

The “mi” key in LS_COLORS was meant to be used for a missing link path, but it wasn’t really used like that. There was also a bug where control characters in a broken symlink’s path were assumed to be underlined, because that’s what happened in the default colour scheme, but this assumption doesn’t hold when colours were disabled.

The solution to these was not to introduce another configurable colour code, but to start using _overlays_ to alter a bunch of colours at once. The “mi” code will have to be added back later.
2017-10-08 17:08:07 +01:00
Benjamin Sago
b95446d834 Thread an ignore cache through the program
!
2017-09-30 09:17:29 +02:00
Benjamin Sago
07443e87ba Add a --git-ignore option that doesn’t do anything
!!
2017-09-30 09:17:28 +02:00
Mahmoud Al-Qudsi
ad02241ac2 Merge branch 'master' into optional_args 2017-09-16 14:28:24 -05:00
Benjamin Sago
c475cccce4 Flip the new/old order, and add suggestion for -lt
I changed my mind about which way round sorting by “newest” or by “oldest” should actually go. If you’re listing a large directory, you see the last lines of the output first, so these files should be the ones with the largest whatever the sort field is. It’s about sorting *last*, not sorting *first*. Sorting by size wouldn’t say “sorts smallest files first”, it would say “sorts largest files last”. Right?

Also, add a new suggestion that warns against “ls -lt”.
2017-09-14 09:18:17 +01:00
Benjamin Sago
a8bf990674 Tie value suggestions to their arguments
This commit changes the definition of Arg so that it knows about which values it can accept, and can display them in the help text. They were already being shown in the help text, but they were passed in separately, so one argument could show two different sets of options if it wanted. Now, the argument itself knows whether there are suggestions, so it doesn’t have to be passed in separately.

This means we can use it for other things, including listing choices when an option is missed out, without having to repeat the list.

With Misfire::BadArgument now only having two fields, it’s not worth using a constructor function anymore.
2017-09-14 01:22:37 +01:00
Mahmoud Al-Qudsi
36cf5df044 Add support for optional argument/flag with optional value
TakesValue::Optional introduced which allows for an optional flag with
an optional value (equivalent to getopts' optflagopt mode).

Can be used where a default value for a modifier could exist, but the
user might prefer to override.

Will be used to implement #284, permitting --time to default to "sort by
modification date" for compatibility with GNU/posix ls but keeping
support for exa's previous behavior.
2017-09-13 18:48:59 -05:00
Benjamin Sago
1824313cda Put misfire.rs in a nicer order
The main type is now at the top.
2017-09-13 23:49:30 +01:00
Benjamin Sago
43bbf00478 Show a warning when running ‘exa -ltr’
Raised in #243 and #284. exa isn’t able to override the -t option like this, so the least it can do is detect that case (which is going to be an error case anyway) and show a suggestion.
2017-09-13 23:47:19 +01:00
Benjamin Sago
0fefc78cbb Add more modified date aliases
I don’t really see the modified date as the *modified* date, rather just the *date* field, because it’s the date field I refer to like 99.9% of the time. So now it has aliases to match.

Also are included are aliases for the reverse order, because I’d rather write “new” than “the reverse of old”.
2017-09-13 23:26:06 +01:00
Benjamin Sago
19b7780755 Fix typo in error message
It said “(Choices: (choices: this, that, other))” instead of “(choices: this, that, other)”. Also improve the same error elsewhere: options more have ‘settings’ than ‘values’.
2017-09-13 22:37:51 +01:00
Benjamin Sago
dc45332d7b Implement file name colouring in {exa,ls}_colors
This commit adds to the parsing of the LS_COLORS and EXA_COLORS variables so that non-two-letter codes (keys other than things like ‘di’ or ‘ln’ or ‘ex’) will be treated as file name globs, and get used to colour files accordingly.

Fixes #116 for good.
2017-09-13 08:51:57 +01:00
Benjamin Sago
b86074d63b Rename Style to Styles to avoid a name clash 2017-09-13 08:44:59 +01:00
Benjamin Sago
28b4b672d4 Move FileStyle to the same options file as Colours
They are going to be deduced together (from the same environment variable) so it makes sense to put them in the same file first.
2017-09-03 19:50:40 +01:00