Skip to content

How to set an environment variable for just the following command? #4979

Answered by halloleo
halloleo asked this question in Q&A
Discussion options

You must be logged in to vote

Ups, found the answer myself: The bash like approach does work -- when I make sure there are no spaces in the definition of the environment variable in front of the command:

$XONSH_DATA_DIR='/new/path' history show all

Sorry to have bothered the community. Happy xonshing!

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@anki-code
Comment options

Answer selected by halloleo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants