xonsh

Python-powered, cross-platform, Unix-gazing shell.

OTHER License

Downloads
69K
Stars
8K
Committers
330

Bot releases are visible (Hide)

xonsh - 0.9.9

Published by scopatz over 5 years ago

Added:

  • $COMPLETION_IN_THREAD: When this is True, background theads is used for completion.
  • Open man page when requesting help for subprocess commands, e.g. using sh?
  • Add several cmds/tools for predict list

Changed:

  • Changed XonshSession.link_builtins to set a DynamicAccessProxy for each builtin link
  • events is now unlinked from builtins

Removed:

  • Removed DeprecationWarningProxy; no longer needed
  • Removed load_proxies and unload_proxies; moved functionality to XonshSession.link_builtins, XonshSession.unlink_builtins, respectively.
  • Removed deprecated builtin.__xonsh_*__ alises, please use builtins.__xonsh__.* instead.

Fixed:

  • Added proxied __dir__ method to DynamicAccessProxy to restore
    tab-completion for objects that use the proxy (especially events)
  • Avoid displaying finished tasks in title.
  • inspect.getsource now works correctly and the __xonsh__.execer resets
    <filename> correctly. This was causing several very strange buggy
    behaviors.
  • Hitting Enter while $VI_MODE=True now executes the current code block
    irrespective of cursor position

Authors:

  • Anthony Scopatz
  • Gil Forsyth
  • David Dotson
  • vaaaaanquish
  • Alexander Steffen
  • Ke Zhang
  • Daniel Smith
xonsh - 0.9.8

Published by scopatz over 5 years ago

Fixed:

  • Fixed a bug in sourcing Bash functions, where delare -F contained
    newlines, meaning that the read command that followed it would only
    pick up the first function declaration. echo is used to normalize
    whitespace.

Authors:

  • Anthony Scopatz
xonsh - 0.9.7

Published by scopatz over 5 years ago

Added:

  • add xontrib (xontrib-readable-traceback)
  • Registered kitty xontrib.
  • The zipapp extra was added to install the importlib.resources backport on <3.7

Changed:

  • turn off warning on completer
  • xontrib metadata loading is now zipapp safe when possible

Fixed:

  • Updated py-bash-completion that is vended with xonsh to v0.2.6 which
    includes a fix completion which uses a subshell environment and a
    fix for string index error in stripped prefix.
  • Removed obsolte "Alt+." keybinding in xontrib-bashisms that was causing built-in binding to malfunction.
  • Fixed that occurs when type a command before rendering.

Authors:

  • Anthony Scopatz
  • Jamie Bliss
  • con-f-use
  • vaaaaanquish
  • Gyuri Horak
xonsh - 0.9.6

Published by scopatz over 5 years ago

Fixed:

  • Fixed exception in help/version threadable predictor
  • Fixed gitstatus prompt so that it also now reports deleted files
  • Fixed issue where the prompt-toolkit2 shell could not display and
    would end up in an infinite error loop if $MULTILINE_PROMPT
    was a suitably "false" value, such as None or an empty string.
  • Fixed issue where setting $XONSH_STDERR_PREFIX and $XONSH_STDERR_POSTFIX
    and running a command in the xonshrc file would throw an error.

Authors:

  • Anthony Scopatz
  • David Strobach
  • virus
  • shadow-light
xonsh - 0.9.5

Published by scopatz over 5 years ago

Fixed:

  • Style 'bw'. Background colors was added in the style description.
  • Fix causing error in get_predictor_threadable on windows when try to run not exist command
  • pip completer no longer fires when pip happens to appear within a word
    like bagpipes
  • Fixed issue with history gc command not running properly.

Authors:

  • Anthony Scopatz
  • Gil Forsyth
  • Jean-Benoist Leger
  • virus
  • con-f-use
xonsh - 0.9.4

Published by scopatz over 5 years ago

Added:

  • Add processing %d for avoid overwriting in run-tests.xsh

Changed:

  • Xonsh now does not attempt to expand raw strings, so now::

    $ echo "$HOME"
    /home/user
    $ echo r"$HOME"
    $HOME

  • sudoedit now runs unthreaded

Fixed:

  • threadable predictor for 'env' command based on predictor from the executed
    command. Fixes #2759 and #3103.
  • An error in the 'xon.sh' executable that only popped up during testing has
    been fixed. Specifically: It now directly calls 'python3' without invoking
    'env'.
  • bashisms extension can be used again with prompt_toolkit v1
  • Fix a crash when setting $INTENSIFY_COLORS_ON_WIN in certain situations.
  • Fix issue with bashsisms xontrib causing syntax errors for some Python statements
  • portable trick to pass args which replace '/usr/bin/env' is removed and
    '/usr/bin/env' is used. Fixes bug when a python3 used is outside the default
    'PATH'.

Authors:

  • Anthony Scopatz
  • Morten Enemark Lund
  • Jean-Benoist Leger
  • David Strobach
  • virus
  • Carmen Bianca Bakker
  • con-f-use
  • cclauss
  • Eddie Peters
xonsh - 0.9.3

Published by scopatz over 5 years ago

Deprecated:

  • Python v3.4 has been fully, completely, and (hopefully) correctly
    deprecated. Please migrate to an officially supported version of Python.

Authors:

  • Anthony Scopatz
xonsh - 0.9.2

Published by scopatz over 5 years ago

Changed:

  • For aliases, predictor is build with the predictor of original command, in
    place of default predictor.

Fixed:

  • Updated setup.py to require Python 3.4 using the python_requires keyword.
    This rectifies issues with pip installing xonsh. Python 3.4 support will
    be removed on the following release.

Authors:

  • Anthony Scopatz
  • Jean-Benoist Leger
xonsh - 0.9.1

Published by scopatz over 5 years ago

Changed:

  • We no longer manually check the Python version in setup.py,
    but instead use the setuptools python_requires feature.

Fixed:

  • Updates for integrating with new colors styles in Pygments v2.4.0.

Authors:

  • Anthony Scopatz
xonsh - 0.9.0

Published by scopatz over 5 years ago

Added:

  • Implemented the following "bang command" bashisms: !$, $*, !^,
    and !<str>. These are in addition to !!, which was already
    implemented.
  • asciinema (terminal recorder) added in not threadable commands.
  • tput added in not threadable commands.
  • New color_tools.KNOWN_XONSH_COLORS frozenset.
  • New pyghooks.PYGMENTS_MODIFIERS mapping from color modifier names to
    pygments colors.
  • New pyghooks.color_name_to_pygments_code() function for converting
    color names into pygments color codes.

Changed:

  • Circle now runs black checks on contents of bundled xontribs

  • The black checks no longer skip some files buried deeper in the directory
    tree.

  • Errors while formatting the prompt are highlighted for easier debugging.

  • Pygments styles only define the standard set of colors, by default.
    Additional colors are computed as needed.

  • PTYs created for running threadable command have now size set to same size
    than main terminal.

  • Update documentation pointing to the minimal required version of
    Python (3.5).

Deprecated:

  • Drop support for Python 3.4.

Removed:

  • pyghooks.KNOWN_COLORS is no longer needed or useful as pygments colors
    are computed automatically.
  • style_tools.KNOWN_COLORS was never used, redundant with
    pyghooks.KNOWN_COLORS and has thus been removed.

Fixed:

  • Fixed a DeprecationWarning that would show up during an import of MutableSet.
  • Fixed error with aliases composed of functions wrapped in functools.partial.
  • black formatted all xontribs
  • deleting a non existing environement variable with default value do nothing
    instead of raising a exception trying to deleting it in existing values dict.
  • Fixed crash while converting ANSI color codes with leading zeroes
  • Fixed crash while parsing invalid ANSI color code
  • fix causing infinite loop when doing cat empty file
  • Fixed issue which occurs when user doesn't have access to parent directory and
    xonsh scan all parents directory to find if we are in a Hg repository.
  • Fixed issue with pygments-cache not properly generating a cache the first
    time when using prompt-toolkit when using ptk2.
    This was due to a lingering lazy import of pkg_resources
    that has been removed.
  • Minor update for Python v3.8.
  • Fixed a "'NoneType' object is not iterable" bug when looking up stty
    in command cache.
  • The release tarball now includes all test files.
  • Arguments passed to python in 'scripts/xonsh' and in 'scripts/xonsh-cat' are
    now passed by a portable hack in sh, not anymore by /usr/bin/env.

Authors:

  • Anthony Scopatz
  • Gil Forsyth
  • Jean-Benoist Leger
  • David Strobach
  • virus
  • Carmen Bianca Bakker
  • Alexander Sosedkin
  • Kale Kundert
  • Andrés García García
  • Andrés García García
  • Samuel Dion-Girardeau
  • Steven Kryskalla
  • Rodrigo Oliveira
xonsh - 0.8.12

Published by scopatz over 5 years ago

Added:

  • Support for more ANSI escape sequece modifers allowed in color names.
    The current modifiers now allowed are: BOLD, FAINT, ITALIC, UNDERLINE,
    SLOWBLINK, FASTBLINK, INVERT, CONCEAL, and STRIKETHROUGH.
  • New ansi_tools.ansi_color_name_to_escape_code() function for
    converting a color name to an ANSI escape code.
  • color_tools.RE_XONSH_COLOR is a regular expression for matching
    xonsh color names.
  • color_tools.iscolor() is a simple function for testing whether a
    string is a valid color name or not.
  • The tools.all_permutations() function yeilds all possible permutations
    of an iterable, including removals.

Changed:

  • change url of xontrib-autojump
  • ANSI color styles may now defined simply by their plain and intense colors.
  • SET_FOREGROUND_3INTS_ renamed to SET_FOREGROUND_FAINT_,
    SET_BACKGROUND_3INTS_ renamed to SET_BACKGROUND_FAINT_,
    SET_FOREGROUND_SHORT_ renamed to SET_FOREGROUND_SLOWBLINK_, and
    SET_BACKGROUND_SHORT_ renamed to SET_BACKGROUND_SLOWBLINK_.

Removed:

  • ansi_tools.ANSI_REVERSE_COLOR_NAME_TRANSLATIONS removed, as it is
    no longer needed.

Fixed:

  • Fixed issues where $LS_COLORS could not convert valid ANSI colors.

Authors:

  • Anthony Scopatz
  • virus
xonsh - 0.8.11

Published by scopatz over 5 years ago

Added:

  • New xonsh.color_tools.short_to_ints() function for directly
    converting a short (0 - 256) color into a 3-tuple of ints
    represeting its RGB value.
  • New xonsh.ansi_colors.ansi_reverse_style() function for
    converting a mapping of color names to ANSI escape codes into
    a mapping from escape codes into color names. This is not a
    round-trippable operation.
  • New xonsh.ansi_colors.ansi_color_escape_code_to_name() function
    for converting an ANSI color escape code into the closest xonsh
    color name for a given style.
  • New xonsh.events.EventManager.exists() method enables the checking
    of whether events actually exist with out making the event if it
    doesn't exist.
  • New command-specific event categories called on_pre_spec_run_<cmd-name>
    and on_post_spec_run_<cmd-name> will be fired before and after
    SubpocSpec.run() is called. This allows for command specific
    events to be executed. For example, on_pre_spec_run_ls would
    be run prior to an invocation of ls.
  • New xonsh.environ.LsColors class for managing the $LS_COLORS
    environment variable. This ensures that the ls command respects the
    $XONSH_COLOR_STYLE setting. An instance of this class is added to the
    environment when either the $LS_COLORS class is first accessed or
    the ls command is executed.
  • The on_pre_spec_run_ls event is initialized with a default handler
    that ensures that $LS_COLORS is set in the actual environment prior
    to running an ls command.
  • New xonsh.tools.detype() function that simply calls an objects own
    detype() method in order to detype it.
  • New xonsh.tools.always_none() function that simply returns None.
  • New Env.set_ensurer() method for setting an ensurer on an environment.

Changed:

  • The black and white style bw now uses actual black and white
    ANSI colore codes for its colors, rather than just empty color
    sequences.

  • An environment variable detype operation no longer needs to be
    function, but may also be None. If None, this variable is
    considered not detypeable, and will not be exported to subprocess
    environments via the Env.detype() function.

  • An environment variable detype function no longer needs to return
    a string, but may also return None. If None is returned, this
    variable is considered not detypeable, and will not be exported to
    subprocess environments via the Env.detype() function.

  • The Env.detype() method has been updated to respect the new
    None types when detyping.

  • The xonsh.tools.expandvars() function has been updated to respect
    the new None types when detyping.

  • The xonsh.xonfig.make_xonfig_wizard() function has been updated to respect
    the new None types when detyping.

  • Event handlers may now be added and discarded during event firing for
    normal events. Such modifications will not be applied to until the
    current firing operation is concluded. Thus you won't see newly added
    events fired.

  • xonsh now uses its own vended version of ply. Any installed versions will no longer be used. This reflects that ply is no
    longer distributed as an installable packages.

  • Updated to used ply version 3.11.

  • Reverted change in give_to_terminal to restore working version of
    cmake, rm -i, etc. This breaks pv | head.

Deprecated:

  • The xonsh.color_tools.make_pallete() function is no
    longer deprecated, as it is actually needed in other parts of
    xonsh still, such as pyghooks.

Removed:

  • All code references to $FORMATTER_DICT have been removed.

Fixed:

  • Resolved issues where macro functions were not able to properly
    accept single-line statements in exec and single mode.

  • Minor fixes to xonsh.events.debug_level().

  • Fixed a regression where some interactive commands were not waited for
    properly for long enough.

  • Fixed environments not showing in the prompt when using Anaconda Python.

  • Fixed regression with anaconda activate/deactivate scripts not wokring on Windows.

Authors:

  • Anthony Scopatz
  • Morten Enemark Lund
xonsh - 0.8.10

Published by scopatz over 5 years ago

Added:

  • New xonsh.aliases.partial_eval_alias() function and related classes
    for dispatching and evaluating partial alias applications for callable
    aliases.

Changed:

  • Subprocesses will no longer close file descriptors automatically.
    This was causing issues with other commands that expected file
    descriptors to remain open, such as make.
  • The xonsh.Aliases.eval_alaises() method updated to use
    xonsh.aliases.partial_eval_alias().

Fixed:

  • Fixed xonsh.completers.base.complete_base() to no longer throw an
    error caused by complete_python() sometimes returning a tuple.
    This fixes cases such as ls &&<TAB>.
  • Fixed regression with line continuations in implicit subprocess mode within
    indented blocks of code, such as if-statements.
  • Resolved issue where setting empty signal masks was causing the
    terminal to close. This was problematic for certain command
    pipelines. For example, pv /dev/urandom | head now works.
  • Prevents recurssive errors from being raised when there is no child process
    in xonsh.jobs.wait_for_active_job().
  • Tweaked xonsh.completers.commands.complete_skipper() to insert a space following
    certain tokens (&&, ||, |, and, or) to avoid overwriting existing tokens
    with completer output.
  • Fixed bug with evaluating recurssive aliases that did not implement
    the full callable alias signature.

Security:

  • ,

Authors:

  • Anthony Scopatz
  • Gil Forsyth
  • Troy de Freitas
xonsh - 0.8.9

Published by scopatz over 5 years ago

Added:

  • New env_prefix & env_postfix prompt fields for rendering the pre- and
    post-fix characters of the an active virtual environment.
  • ON_WSL attribute in platform.py
  • Rendering of {env_name} in $PROMPT is now suppressed if
    the $VIRTUAL_ENV_DISABLE_PROMPT environment variable is
    defined and truthy.
  • Rendering of {env_name} in $PROMPT is now overridden by
    the value of str($VIRTUAL_ENV_PROMPT) if that environment variable
    is defined and not None. $VIRTUAL_ENV_DISABLE_PROMPT takes precedence
    over $VIRTUAL_ENV_PROMPT.
  • A xontrib which adds support for direnv <https://direnv.net/>_

Changed:

  • env_name prompt field now looks up the pre- and post-fix characters,
    rather than relying on hard-coded values.
  • Some minor history show efficiency improvements.
  • If we are on wsl, avoid to use xonsh_preexec_fn when pipe.

Fixed:

  • Made $PATH searching more robust to broken symlinks on Windows.
  • undesirable SIGSTOP by putting in a SIGCONT
  • Fixed issue with recursive aliases not being passes all keyword arguments
    that are part of the callable alias spec. This allows commands like
    aliases['hsa'] = "history show all"; hsa | head to no longer fail
    with strange errors.

Authors:

  • Anthony Scopatz
  • Sagar Tewari
  • Brian Skinn
  • Yohei Tamura
  • anatoly techtonik
  • 74th
  • Chad Kennedy
xonsh - 0.8.8

Published by scopatz almost 6 years ago

Added:

  • vox new has an added -p --interpreter flag for choosing the python interpreter to use for virtualenv creation
  • The default Python intrepreter vox uses to create virtual environments can be set using the $VOX_DEFAULT_INTERPRETER environment variable.

Changed:

  • lib.ChainDB now resolves results to the type of the inputs if possible
xonsh - 0.8.7

Published by scopatz almost 6 years ago

Added:

  • New xonsh syntax pf strings -- combining path strings with f-strings.

    Usage:

    .. code-block:: bash
    gil@bad_cat ~ $ repos = 'github.com'
    gil@bad_cat ~ $ pf"~/{repos}"
    PosixPath('/home/gil/github.com')
    gil@bad_cat ~ $ pf"{$HOME}"
    PosixPath('/home/gil')
    gil@bad_cat ~ $ pf"/home/${'US' + 'ER'}"
    PosixPath('/home/gil')

Fixed:

  • Set ls to predict_true in default_threadable_predictors. This prevents ls on OSX
    from being flagged on OSX as unthreadable (incorrectly) because it relies on ncurses.
xonsh - 0.8.6

Published by scopatz almost 6 years ago

Added:

  • Doco about how to update xonsh and how to set and unset environment variables

Fixed:

  • Updated behavior of the cat coreutils function so that it properly
    handles as vareity of cases such as:

    • Exits after concatenating normal files which have a finite size
    • Continues to run for special files which do not have a size,
      such as /dev/random
    • Is interruptable in all cases with Crtl-C.
  • Callable aliases were not properly raising a CalledProcessError when they
    returned a non-zero exist status when $RAISE_SUBPROC_ERROR = True. This has
    been fixed.

  • Fixed interpretation of color names with PTK2 and Pygments 2.3.1.

xonsh - 0.8.5

Published by scopatz almost 6 years ago

Added:

  • Add alias to base16 shell <https://github.com/chriskempson/base16-shell>_

  • Installation / Usage

    1. To install use pip

    .. code-block:: bash

      python3 -m pip install xontrib-base16-shell
    
    1. Add on ~/.xonshrc

    .. code:: python
    :number-lines:

      $BASE16_SHELL = $HOME + "/.config/base16-shell/"
      xontrib load base16_shell
    
    1. See image

    .. image:: https://raw.githubusercontent.com/ErickTucto/xontrib-base16-shell/master/docs/terminal.png
    :width: 600px
    :alt: terminal.png

  • New DumbShell class that kicks in whenever $TERM == "dumb".
    This usually happens in emacs. Currently, this class inherits from
    the ReadlineShell but adds some light customization to make
    sure that xonsh looks good in the resultant terminal emulator.

  • Aliases from foreign shells (e.g. Bash) that are more than single expressions,
    or contain sub-shell executions, are now evaluated and run in the foreign shell.
    Previously, xonsh would attempt to translate the alias from sh-lang into
    xonsh. These restrictions have been removed. For example, the following now
    works:

    .. code-block:: sh

    $ source-bash 'alias eee="echo aaa \$(echo b)"'
    $ eee
    aaa b
    
  • New ForeignShellBaseAlias, ForeignShellFunctionAlias, and
    ForeignShellExecAlias classes have been added which manage foreign shell
    alias execution.

Changed:

  • String aliases will now first be checked to see if they contain sub-expressions
    that require evaluations, such as @(expr), $[cmd], etc. If they do,
    then an ExecAlias will be constructed, rather than a simple list-of-strs
    substitutiuon alias being used. For example:

    .. code-block:: sh

    $ aliases['uuu'] = "echo ccc $(echo ddd)"
    $ aliases['uuu']
    ExecAlias('echo ccc $(echo ddd)\n', filename='<exec-alias:uuu>')
    $ uuu
    ccc ddd
    
  • The parse_aliases() function now requires the shell name.

  • ForeignShellFunctionAlias now inherits from ForeignShellBaseAlias
    rather than object.

Fixed:

  • Fixed issues where the prompt-toolkit v2 shell would print an extra newline
    after Python evaluations in interactive mode.
xonsh - 0.8.4

Published by scopatz almost 6 years ago

Added:

  • Added the possibility of arbitrary paths to the help strings in vox activate and
    vox remove; also updated the documentation accordingly.
  • New xonsh.aliases.ExecAlias class enables multi-statement aliases.
  • New xonsh.ast.isexpression() function will return a boolean of whether
    code is a simple xonsh expression or not.
  • Added top-level run-tests.xsh script for safely running the test suite.

Changed:

  • String aliases are no longer split with shlex.split(), but instead use
    xonsh.lexer.Lexer.split().

  • Update xonsh/prompt/cwd.py _collapsed_pwd to print 2 chars if a directory begins with "."

  • test which determines whether a directory is a virtualenv

    previously it used to check the existence of 'pyvenv.cfg'
    now it checks if 'bin/python' is executable

Fixed:

  • Fixed issue with and & or being incoreectly tokenized in implicit
    subprocesses. Auto-wrapping of certain subprocesses will now correctly work.
    For example::

    $ echo x-and-y
    x-and-y
    
  • Fix EOFError when press control+d

  • fix no candidates if no permission files in PATH

  • Fixed interpretation of color names with PTK2 and Pygments 2.3.

  • Several ResourceWarnings: unclosed file in tests

  • AttributeError crash when using --timings flag

  • issue #2929

xonsh - 0.8.3

Published by scopatz almost 6 years ago

Added:

  • Dociumentation paragrapgh about gow to run xonsh in Emacs shell

Changed:

  • Updated what pip requirements are needed to build the documnetaion
  • $XONSH_TRACEBACK_LOGFILE now beside strings also accepts os.PathLike
    objects.
  • Updated vended version of ply to 3.11
  • Deprecation warnings now print from stacklevel 3.

Fixed:

  • Annotation assignment statements (e.g. x : int = 42) are now supported.

  • Fixed error output wording for fg and bg commands

  • Flake8 errors

  • xonsh can now properly parse import statements with trailing comma within
    parentheses, e.g.::

    from x import (y, z,)

  • ResourceWarning: unclosed scandir iterator in imphooks.py

  • Removed use of deprecated inspect.formatargspec() for inspect.signature()

  • Makefile directive that updates vended version of ply