Releases: xonsh/xonsh
Releases · xonsh/xonsh
0.19.4
0.19.3
Changed:
- On Windows, cmd.exe-based aliases now resolve to %SystemRoot%\System32\cmd.exe by default (and fallback to COMSPEC only if the former cannot be found).
Fixed:
- Using
trace on
with.xsh
scripts could previously lead to
a spurious ignored exception showing up on stderr. This is now fixed. - pipelines: fixed
'NoneType' object has no attribute 'pid'
exception (#5794).
Security:
- The
history delete
action on the sqlite backend used to
pass matched history lines to a SQL statement without sanitization.
This could lead to unexpected SQL being run on the history database.
This is now fixed. Security risk: low.
Authors:
- anki-code
- Jason R. Coombs
- Łukasz Langa
- Ahmed
0.19.2
Added:
- env: add
$XONSH_PROMPT_CURSOR_SHAPE
for configuring prompt cursor shape. - env: Added
$XONSH_CONFIG_DIR
,$XONSH_DATA_DIR
and$XONSH_CACHE_DIR
. - SIGHUP will now be forwarded to child processes when received by the main xonsh process.
This matches the behavior of other shells e.g. bash. - Documented the fact that the
on_postcommand
event only fires in interactive mode. - history: Added and documented
--session-id
parameter forhistory pull
command. - history-json: Implemented
history pull
for JSON history backend.
Fixed:
- Running a subcommand in an event handler will no longer block xonsh from exiting.
- history: Prevented
history pull
command from adding consecutive duplicates to propmter history. - prompt toolkit: Fixed autosuggest sometimes not updating when up-arrow is pressed (#5787).
- Subprocess-based completions like
xontrib-fish-completer <https://github.com/xonsh/xontrib-fish-completer>
_
no longer append a space if the single available completion ends with
a directory separator. This is consistent with the behavior of the
default completer.
Authors:
- anki-code
- jfmontanaro
- Artur Manuel
- Đỗ Trung Nguyên
- Łukasz Langa
0.19.1
0.19.0
Added:
- Env: Added
$XONSH_SUPPRESS_WELCOME
variable to suppress the welcome message.
Changed:
- Replaced
case_insensitive_dictionary
dependency with localCaseInsensitiveDict
class.
Fixed:
- Parsers: support python3.13: fix deprecation warnings.
- Fix DeprecationWarning while initializing Expression.
Authors:
- Evgeny
- doronz88
- JamesParrott
- Jueun Lee
- Simon Billinge
- Bala
- Gil Forsyth
0.18.4
Changed:
- Now SystemExit that invoked from callable alias follows to exiting from callable alias instead of exiting the entire shell.
Fixed:
- Built-in commands such as
xonfig -h
andxontrib -h
no longer cause the shell to exit. - Fixed incorrect quoting behaviour in
activate.xsh
for virtualenv version 20.26.6.
Authors:
- anki-code
- pre-commit-ci[bot]
- Peter Ye
- Max Nordlund
- Shawn Wallace
- Faidon Liambotis
0.18.3
Added:
- executables: Added
locate_relative_path
functionality tolocate_file
.
Changed:
$MULTILINE_PROMPT
changed from'.'
to' '
(space)
to have an ability to copy the multiline functions from shell history without deleting the dot manually (#5624 #5634).
Fixed:
- Fixed
$AUTO_CD
regress after previous refactoring. - Partial fix for "Bad file descriptor" in case of callable alias with execx invocation inside e.g. ExecAlias (#5645).
- completer: Fixed exception when in python-only completion context (#5632).
- Fixed exception "object has no attribute readlines" in case of redirect callable alias output.
Authors:
- Gil Forsyth
- Noortheen Raja
- anki-code
- pre-commit-ci[bot]
- Aidan Courtney
0.18.2
0.18.1 (deprecated)
- Maintenance
0.18.0 (deprecated)
Key points in this release from @anki-code:
- Completion of the "decorator alias" concept. See also xontrib-dalias.
- Performance improvements after introduction of new resolver for Linux and Mac. Testing Windows is in progress, waiting for reports.
- Refactoring of internal structure.
Added:
- Added
@aliases.return_command
decorator to eliminate the need to wrap the logic for modifying command into callable alias wrapper (#5473 by @anki-code). - aliases: Added ability to set multiple decorator aliases e.g.
j = $(@json @noerr echo '{}')
(by @anki-code). - Tutorial: added example of callable environment variable (by @anki-code).
- env: Added
$XONSH_MODE
variable to detect the current execution mode:
interactive
,script_from_file
,source
,single_command
,script_from_stdin
. (by @anki-code) - Builtin:
exit
can return exit code e.g.exit 71
. (by @anki-code) - builtin: added
__xonsh__.imp
to have an ability to import and use modules immediately in one line
e.g.__xonsh__.imp.json.loads('{}')
. (by @anki-code)
In the future__xonsh__
will have short notation@
and the line will looks more elegant@.imp.json.loads('{}')
. - builtins: Added color to printx e.g.
printx('Good', 'GREEN')
as short alternative toprintx('{GREEN}Good{RESET}')
. (by @anki-code) - Created
xonsh.api
to use xonsh functionality in pure python code and downstream projects (#5383 #5538).
It's usable but don't treat this serios because it's mostly to move some functions into distinct
submodule to reflect the intention to have the API. We need review and improvements here. (by @anki-code) - tools: added
mkdir
toxonsh.tools.chdir
e.g.with chdir('/tmp/new', mkdir=True): pass
. (by @anki-code)
Changed:
- New executable resolving method was introduced and the commands_cache usages were replaced in the key places. As result we expect speed up in xonsh startup, reducing lagging during typing in prompt and speed ups during the commands execution (#5544 by @anki-code).
COLOR_RESULTS
switched toFalse
for non-interactive command case to improve speed in default behavior (#5562).- main: Importing sqlite became optional. (by @anki-code)
- prompt: Switching to prompt_toolkit in edge case of sending stdin to interactive mode (#5462 #5517 by @anki-code).
- Rename:
SpecModifier
,xthread
,xunthread
renamed toDecoratorAlias
,@thread
,@unthread
to support idea that
spec modifier is like a Python decorator. (by @anki-code) - Big refactoring of internal modules structure to give clear understanding of internal xonsh components (#5538).
E.g. if you haveimport xonsh.jobs
convert this toimport xonsh.procs.jobs
.
This kind of refactoring occurs once per many years. (by @anki-code)
Deprecated:
- Starting from this release we notify that in the future we will not recommend to use
xonsh.procs.run_subproc
andxonsh.built_ins.subproc_*
functions for downstream projects because of #5383.
We will developxonsh.api
as alternative.
Removed:
- xontrib: Do not autoload xontribs in
xonsh --no-rc
mode. (by @anki-code)
Fixed:
- Callable alias: fixed capturing stdout in case of redirect e.g.
a > file
(#5527 by @anki-code). - Commands Cache: Fixed cache update logic that lead to lagging during typing. (by @anki-code)
- Replaced deprecated
sys.last_type, sys.last_value, sys.last_traceback
withsys.last_exc
. (by @kulkarniniraj) - Fixed
history gc
invocation failing whensqlite
history backend is used. (by @jnoortheen)
Authors:
- anki-code @anki-code
- Jason R. Coombs @jaraco
- Noortheen Raja @jnoortheen
- lunrenyi @lunrenyi
- Spencer Bliven @sbliven
- Niraj Kulkarni @kulkarniniraj
- Gil Forsyth @gforsyth