swc-windows-installer.py: Quote $PATH export to account for spaces.
authorNeal Davis <davisneale@gmail.com>
Mon, 27 Jan 2014 20:41:04 +0000 (14:41 -0600)
committerW. Trevor King <wking@tremily.us>
Mon, 27 Jan 2014 21:24:02 +0000 (13:24 -0800)
Many people have spaces in their Windows user names, leading to
trouble with an unquoted $PATH export.  This file now quotes the $PATH
addition accordingly.

swc-windows-installer.py

index 041642ac0a60c8bff27d1667231aa2a3e97e71e8..f10377deb6fc652e6ef9ddfb464872bde3e8c7e2 100755 (executable)
@@ -83,7 +83,7 @@ def update_bash_profile(extra_paths=()):
     lines = [
         '',
         '# Add paths for Software-Carpentry-installed scripts and executables',
-        'export PATH=$PATH:{}'.format(':'.join(
+        'export PATH=\"$PATH:{}\"'.format(':'.join(
             make_posix_path(path) for path in extra_paths),),
         '',
         '# Make nano the default editor',