[CHANGELOG] Reorganize

This should make it more attractive to those not in the know.
This commit is contained in:
Fabian Homborg 2018-09-29 00:40:25 +02:00
parent 444f9f8715
commit d62731a931

View File

@ -10,72 +10,77 @@ fish 3.0 is a major release which brings with it both improvements in functional
- `?` as a glob is deprecated and will be removed in the future. (#4520). This is controlled by the `qmark-noglob` feature flag.
## Notable non-backward compatible changes
- `read` now uses `-s` as short for `--silent` (à la `bash`); `--shell`'s abbreviation (formerly `-s`) is now `-S` instead (#4490).
- `set x[1] x[2] a b` is no longer valid syntax (#4236).
- `for` loop control variables are no longer local to the `for` block (#1935).
- `%` is no longer used for process and job expansion. `$fish_pid` and `$last_pid` have taken the place of `%self` and `%last` respectively. Some commands have been wrapped to still understand process expansion, including `bg`, `fg` and `kill` (#4230, #1202)
- A literal `{}` now expands to itself, rather than nothing. This makes working with `find -exec` easier. (#1109, #4632)
- Successive commas in brace expansions are handled in less surprising manner (`{,,,}` expands to four empty strings rather than an empty string, a comma and an empty string again). (#3002, #4632).
- `%` is no longer used for process and job expansion. `$fish_pid` and `$last_pid` have taken the place of `%self` and `%last` respectively. (#4230, #1202)
- `for` loop control variables are no longer local to the `for` block (#1935).
- Variables set in `if` and `while` conditions are available outside the block (#4820).
- Local exported (`set -lx`) vars are now visible to functions (#1091).
- `set x[1] x[2] a b` is no longer valid syntax (#4236).
- The new `math` builtin (see below) does not support logical expressions; `test` should be used instead (#4777).
- Range expansion (`$foo[1..5]`) will now always go forward if only the end is negative, and in reverse if just the start is. This is to enable clamping to the last valid index without changing direction if the list has fewer elements than expected.
- Background jobs not first `disown`'d will be reaped upon `exec`, bringing the behavior in line with that of `exit`.
- `read` now uses `-s` as short for `--silent` (à la `bash`); `--shell`'s abbreviation (formerly `-s`) is now `-S` instead (#4490).
## Notable fixes and improvements
- Add completions for openbsd's doas.
### Syntax/semantic changes and new builtins
- fish now supports `&&`, `||`, and `!` (#4620).
- Variables may be used as commands (#154).
- A new feature flags mechanism is added for staging deprecations and breaking changes. Feature flags may be specified at launch with `fish --features ...` or by setting the universal `fish_features` variable. (#4940)
- `exec` now triggers the same safety features as `exit` and prompts for confirmation if background jobs are running.
- `wait` builtin is added for waiting on processes (#4498).
- `math` is now a builtin rather than a wrapper around `bc` (#3157). The default scale is now 6, so that floating point computations produce decimals (#4478).
- Using a read-only variable in a for loop is now an error. Note that this never worked. It simply failed to set the for loop var and thus silently produced incorrect results (#4342).
- Arguments to `end` are now errors, instead of being silently ignored.
- Setting `$PATH` no longer warns on non-existent directories, allowing for a single $PATH to be shared across machines (e.g. via dotfiles).
- A pipe at the end of a line now allows the job to continue on the next line (#1285).
- The names `argparse`, `read`, `set`, `status`, `test` and `[` are now reserved and not allowed as function names. This prevents users unintentionally breaking stuff (#3000).
- `while` sets `$status` to a more useful value (#4982)
- Command substitution output is now limited to 10 MB by default (#3822).
- The machine hostname, where available, is now exposed as `$hostname` which is now a reserved variable. This drops the dependency on the `hostname` executable (#4422).
- The universal variables file no longer contains the MAC address. It is now at the fixed location `.config/fish/fish_universal_variables` (#1912).
### New features in builtins
- `alias` now has a `-s` and `--save` option to save the function generated by the alias using `funcsave` (#4878).
- `bind` has a new `--silent` option to ignore bind requests for named keys not available under the current `$TERMINAL` (#4188, #4431).
- `complete` now has a `-k` and `--keep-order` option to keep the order of the `OPTION_ARGUMENTS` (#361).
- `exec` now triggers the same safety features as `exit` and prompts for confirmation if background jobs are running.
- `funced` now has a `-s` and `--save` option to automatically save the edited function after successfully editing (#4668).
- `functions --handlers` can be used to show event handlers (#4694).
- The `-d` option to `functions` to set the description of an existing function now works; before 3.0 it was documented but unimplemented. Note that the long form `--description` continues to work. (#5105)
- `history search` supports globs for wildcard searching (#3136).
- The `jobs` builtin now has a `-q` and `--quiet` option to silence the output.
- `read` has a new `--delimiter` option as a better alternative to the `IFS` variable (#4256).
- `read` writes directly to stdout if called without arguments (#4407)
- `read` can now read one or more individual lines from the input stream without consuming the input in its entirety via `read -L/--line`. Refer to the `read` documentation for more info.
- `set` has a new `--append` and `--prepend` option (#1326).
- `set` has a new `--show` option to show lots of information about variables (#4265).
- `complete` now has a `-k` and `--keep-order` option to keep the order of the `OPTION_ARGUMENTS` (#361).
- Local exported (`set -lx`) vars are now visible to functions (#1091).
- `string split` supports `-n/--no-empty` to exclude empty strings from the result (#4779).
- `string` builtin has new commands `split0` and `join0` for working with NUL-delimited output.
- `test` and `[` now support floating point values in numeric comparisons.
### Performance improvements
- `abbr` has been reimplemented to be faster. This means the old `fish_user_abbreviations` variable is ignored (#4048).
- Setting variables is much faster (#4200, #4341).
- Using a read-only variable in a for loop is now an error. Note that this never worked. It simply failed to set the for loop var and thus silently produced incorrect results (#4342).
- `math` is now a builtin rather than a wrapper around `bc` (#3157). The default scale is now 6, so that floating point computations produce decimals (#4478).
- `history search` supports globs for wildcard searching (#3136).
- `bind` has a new `--silent` option to ignore bind requests for named keys not available under the current `$TERMINAL` (#4188, #4431).
- Globs are faster (#4579).
- `string` reads from stdin faster (#4610).
- `string split` supports `-n/--no-empty` to exclude empty strings from the result (#4779).
- Slicing $history (in particular, `$history[1]` for the last executed command) is much faster.
### Interactive improvements and completions
- `cd` tab completions no longer descend into the deepest unambiguous path (#4649).
- `sudo` completions now provide completions for the target of the sudo command.
- Setting `$PATH` no longer warns on non-existent directories, allowing for a single $PATH to be shared across machines (e.g. via dotfiles).
- `funced` now has a `-s` and `--save` option to automatically save the edited function after successfully editing (#4668).
- Arguments to `end` are now errors, instead of being silently ignored.
- Pager navigation has been improved. Most notably, moving down now wraps around, moving up from the commandline now jumps to the last element and moving right and left now reverse each other even when wrapping around (#4680).
- Typing normal characters while the completion pager is active no longer shows the search field. Instead it enters them into the command line, and ends paging (#2249).
- A new input binding `pager-toggle-search` toggles the search field in the completions pager on and off. By default this is bound to control-s.
- Slicing $history (in particular, `$history[1]` for the last executed command) is much faster.
- The pager will now show the full command instead of just its last line if the number of completions is large (#4702).
- Tildes in file names are now properly escaped in completions (#2274).
- A pipe at the end of a line now allows the job to continue on the next line (#1285).
- The names `argparse`, `read`, `set`, `status`, `test` and `[` are now reserved and not allowed as function names. This prevents users unintentionally breaking stuff (#3000).
- Wrapping completions (from `complete -w` or `function -w`) can now inject arguments. For example, `complete gco -w 'git checkout'` now works properly (#1976). The `alias` function has been updated to respect this behavior.
- The `jobs` builtin now has a `-q` and `--quiet` option to silence the output.
- fish now supports `&&`, `||`, and `!` (#4620).
- The machine hostname, where available, is now exposed as `$hostname` which is now a reserved variable. This drops the dependency on the `hostname` executable (#4422).
- `functions --handlers` can be used to show event handlers (#4694).
- Variables set in `if` and `while` conditions are available outside the block (#4820).
- The universal variables file no longer contains the MAC address. It is now at the fixed location `.config/fish/fish_universal_variables` (#1912).
- `alias` now has a `-s` and `--save` option to save the function generated by the alias using `funcsave` (#4878).
- Path completions now support expansions, meaning expressions like `python ~/<TAB>` now provides file suggestions just like any other relative or absolute path. (This includes support for other expansions, too.)
- The `string` builtin has new commands `split0` and `join0` for working with NUL-delimited output.
- The `-d` option to `functions` to set the description of an existing function now works; before 3.0 it was documented but unimplemented. Note that the long form `--description` continues to work. (#5105)
- `test` and `[` now support floating point values in numeric comparisons.
- Autosuggestions try to avoid arguments that are already present in the command line.
- Variables may be used inside commands (#154).
- `while` sets `$status` to a more useful value (#4982)
## Other significant changes
- Command substitution output is now limited to 10 MB by default (#3822).
- Added completions for
- `bd` (#4472)
- `bower`
- `configure` (autoconf only)
- `doas`
- `hjson`
- `j` (autojump #4344)
- `jhipster` (#4472)