- 09 8月, 2017 2 次提交
-
-
由 Benjamin Sago 提交于
The assert_parses function was problematic because it insisted on using assert_eq! to check its contents. This won’t work for any type we want to test that doesn’t implement PartialEq, such as TimeFormat, which holds references to years and date strings and other such. To go about fixing this, the first step is to change that function so it only does the initial processing, rather than the assertion, which is now done outside of it in the test macros instead.
-
由 Benjamin Sago 提交于
Now the code actually starts to use the Strictness flag that was added in the earlier commit! Well, the *code* doesn’t, but the tests do: the macros that create the test cases now have a parameter for which tests they should run. It’s usually ‘Both’ for both strict mode and default mode, but can be specified to only run in one, for when the results differ (usually when options override one another) The downside to strict mode is that, now, *any* call to `matches.has` or `matches.get` could fail, because an option could have been specified twice, and this is the place where those are checked for. This makes the code a little less ergonomic in places, but that’s what the ? operator is for. The only place this has really had an effect is in `Classify::deduce`, which used to just return a boolean but can now fail. In order to more thoroughly test the mode, some of the older parts of the code can now act more strict. For example, `TerminalColours::deduce` will now use the last-given option rather than searching for “colours” before “colors”. Help and Version continue doing their own thing.
-
- 08 8月, 2017 2 次提交
-
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
The value is ignored, but this broke quite a lot of tests that assumed MatchedFlags had only one field. Parsing tests have to have OsStr flags because I couldn’t get that part working right, but in general, some tests now re-use common functionality too.
-
- 07 8月, 2017 7 次提交
-
-
由 Benjamin Sago 提交于
This commit gives IgnorePatterns a bunch of constructor methods that mean its option-parsing sister file doesn’t need to know that it’s a vec of glob patterns inside: it can work with anything that iterates over strings. Now, the options module doesn’t need to know about the glob crate.
-
由 Benjamin Sago 提交于
This commit modifies a specific file timestamp so we test both July (which is 5 characters in French) and December (which is 4 characters in Japanese). It’s also kind of a test for locales as well.
-
由 Benjamin Sago 提交于
This started failing because the behaviour was corrected in #250.
-
由 Benjamin Sago 提交于
fix issue #213 iso date format inversion
-
由 Benjamin Sago 提交于
Fix month name widths once and for all #244
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
Add raw file type for Olympus and Nikon
-
- 06 8月, 2017 15 次提交
-
-
由 Benjamin Sago 提交于
This restriction was originally only there because a standalone --tree wasn’t a thing. Now it’s there, there’s no reason to forbid the combination.
-
由 Nontawat Numor 提交于
-
由 Alfred Sawaya 提交于
-
由 Alfred Sawaya 提交于
To render the date, Exa now find out the month with the longest name among all months, and use the width of that.
-
由 Benjamin Sago 提交于
This merges in exa’s own new options parser, which has the following features: - You can specify an option twice and it’ll use the second one, making aliases usable for defaults (fixes #144) - Lets arguments be specified more than once (fixes #125) Strict mode is not done yet; I just wanted to merge this in because it’s been a while, and there’s work that needs to be done on master so I don’t want them drifting apart any further. It’s likely that you’ll find cases where multiple arguments doesn’t work or where the wrong value is being used. There aren’t tests for *everything* yet, and it still uses global environment variables. # Conflicts: # src/options/view.rs
-
由 Benjamin Sago 提交于
Now I just need to remember to update it. Was suggested in #197.
-
由 Benjamin Sago 提交于
The term_size crate introduced in #237 did things *slightly* differently than exa: it tried to get the terminal width of stdout, stderr, and stdin. This broke some tests that only redirected stdout.
-
由 Benjamin Sago 提交于
Use term_size crate to fetch terminal size.
-
由 Benjamin Sago 提交于
Update filetype.rs
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
Now it’s more like help. There aren’t any other fields in its struct at the moment, but there will be in the future (listing the features, and extremely colourful vanity mode)
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
Now, building the two result vectors doesn’t have to go through at least one field.
-
由 Benjamin Sago 提交于
Originally, both the matched flags and the list of free strings were returned from the parsing function and then passed around to every type that had a ‘deduce’ method. This worked, but the list of free strings was carried around with it, never used. Now, only the flags are passed around. They’re in a new struct which has the methods the Matches had. Both of Matches’s fields are now just data, and all of the methods on MatchedFlags don’t ignore any fields, so it’s more cohesive, at least I think that’s the word. Building up the MatchedFlags is a bit more annoying though because the vector is now hidden behind a field.
-
由 Benjamin Sago 提交于
-
- 05 8月, 2017 5 次提交
-
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
One of the previous tests started to fail, because it was working when it shouldn’t have! It worked up until now because I forgot to flag --level as taking an argument, and “--level 4” still worked with 4 as a filename. So there’s now an early check for that functionality that got lost somewhere.
-
由 Benjamin Sago 提交于
-
由 PJB3005 提交于
Should be cross-platform, one step closer to Windows support.
-
- 04 8月, 2017 2 次提交
-
-
由 pskuza 提交于
Added a few video and audio extensions
-
由 Benjamin Sago 提交于
Testing that a recent PR to rust-users (https://github.com/ogham/rust-users/issues/12) didn’t cause any regressions after updating to v0.5.3 of it.
-
- 27 7月, 2017 7 次提交
-
-
由 Benjamin Sago 提交于
Apparently I forgot to give the --time flag an argument, and this wasn’t actually covered by any of the xtests! Well, it’s tested now. I’m not sure how to handle multiple --time arguments.
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
Fixes #193. --all was treated the same as --all --all; now it’s treated differently.
-
由 Benjamin Sago 提交于
-
由 Benjamin Sago 提交于
**
-
由 Benjamin Sago 提交于
-