Repository: xonsh/xonsh

Issue:
conda init error
Hi! Xonsh is super cool! I'm happy every time I'm writing xonshrc!

Today I tried to install master and got an error with conda init:

```bash
pip install -U git+https://github.com/xonsh/xonsh
xonfig
+------------------+----------------------+
| xonsh            | 0.9.21.dev31         |
| Git SHA          | d42b4140             |
```
```
cat ~/.xonshrc
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
import sys as _sys
from types import ModuleType as _ModuleType
_mod = _ModuleType("xontrib.conda",
                   "Autogenerated from $(/opt/miniconda/bin/conda shell.xonsh hook)")
__xonsh__.execer.exec($("/opt/miniconda/bin/conda" "shell.xonsh" "hook"),
                      glbs=_mod.__dict__,
                      filename="$(/opt/miniconda/bin/conda shell.xonsh hook)")
_sys.modules["xontrib.conda"] = _mod
del _sys, _mod, _ModuleType
# <<< conda initialize <<<
```
```
xonsh
Traceback (most recent call last):
  File "/opt/miniconda/lib/python3.8/site-packages/xonsh/proc.py", line 1737, in wait
    r = self.f(self.args, stdin, stdout, stderr, spec, spec.stack)
  File "/opt/miniconda/lib/python3.8/site-packages/xonsh/proc.py", line 1232, in proxy_two
    return f(args, stdin)
  File "/opt/miniconda/lib/python3.8/site-packages/xonsh/aliases.py", line 583, in source_alias
    print_color(
  File "/opt/miniconda/lib/python3.8/site-packages/xonsh/tools.py", line 1768, in print_color
    builtins.__xonsh__.shell.shell.print_color(string, **kwargs)
AttributeError: 'NoneType' object has no attribute 'shell'
xonsh> 
```

How I can fix this?
Thanks!

## For community
⬇️  **Please click the 👍 reaction instead of leaving a `+1` or 👍  comment**


Comments:

Patch:
diff --git a/news/simple-variables.rst b/news/simple-variables.rst
index 3b1d6478..0592b11f 100644
--- a/news/simple-variables.rst
+++ b/news/simple-variables.rst
@@ -1,7 +1,7 @@
 **Added:**
 
 * Xonsh now supports bash-style variable assignments preceding
-  subprocess commands (e.g. ``$FOO = "bar" bash -c r"echo $FOO"``).
+  subprocess commands (e.g. ``$FOO="bar" bash -c r"echo $FOO"``).
 
 **Changed:**
 
diff --git a/xonsh/parsers/base.py b/xonsh/parsers/base.py
index 2b6ce18e..63d7a82d 100644
--- a/xonsh/parsers/base.py
+++ b/xonsh/parsers/base.py
@@ -3325,11 +3325,7 @@ class BaseParser(object):
         p[0] = ast.Str(s=p1.value, lineno=p1.lineno, col_offset=p1.lexpos)
 
     def p_envvar_assign_left(self, p):
-        """envvar_assign_left : dollar_name_tok EQUALS
-                              | dollar_name_tok WS EQUALS
-                              | dollar_name_tok EQUALS WS
-                              | dollar_name_tok WS EQUALS WS
-        """
+        """envvar_assign_left : dollar_name_tok EQUALS"""
         p[0] = p[1]
 
     def p_envvar_assign(self, p):


Test patch:
diff --git a/tests/test_parser.py b/tests/test_parser.py
index 53f5a4cd..67de9208 100644
--- a/tests/test_parser.py
+++ b/tests/test_parser.py
@@ -2240,6 +2240,10 @@ def test_bang_ls_envvar_listval():
     check_xonsh_ast({"WAKKA": [".", "."]}, "!(ls $WAKKA)", False)
 
 
+def test_bang_envvar_args():
+    check_xonsh_ast({"LS": "ls"}, "!($LS .)", False)
+
+
 def test_question():
     check_xonsh_ast({}, "range?")
 
@@ -2502,7 +2506,7 @@ def test_ls_quotes_3_space():
 
 
 def test_leading_envvar_assignment():
-    check_xonsh_ast({}, "![$FOO= 'foo' $BAR =2 echo r'$BAR']", False)
+    check_xonsh_ast({}, "![$FOO='foo' $BAR=2 echo r'$BAR']", False)
 
 
 def test_echo_comma():