Xonsh: Make history expansion happen earlier

Created on 13 Jun 2016  路  2Comments  路  Source: xonsh/xonsh

Xonsh introduces the !n and !! aliases to execute previous commands.
In bash, those history expansions are among the first to execute making it possible to use them inside of expressions.
Here is an example of command that execute the previous command with elevated privilege in bash and that fail in xonsh : sudo !!

It would be nice to make history expansion happen early in xonsh too.

bug

Most helpful comment

sudo !! is now available using the bashisms xontrib. Just put xontrib load bashisms in your xonshrc and you should be good to go.

All 2 comments

Thanks for reporting @matletix!

sudo !! is now available using the bashisms xontrib. Just put xontrib load bashisms in your xonshrc and you should be good to go.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

battaglia01 picture battaglia01  路  3Comments

ahundt picture ahundt  路  4Comments

daym picture daym  路  3Comments

OJFord picture OJFord  路  6Comments

eugenesvk picture eugenesvk  路  5Comments