prompt: You will be provided with a partial code base and an issue statement explaining a problem to resolve.
  <issue>
  When lacking permissions to write, clone message should quote prefix.
  When trying to install a new package into a location that the user lacks write permissions (read-only root), conda helpfully suggests cloning the environment into a new location:
  
  ```
  CondaIOError: IO error: Missing write permissions in: C:\Program Files\Anaconda
  #
  # You don't appear to have the necessary permissions to install packages
  # into the install area 'C:\Program Files\Anaconda'.
  # However you can clone this environment into your home directory and
  # then make changes to it.
  # This may be done using the command:
  #
  # $ conda create -n my_deathstar --clone=C:\Program Files\Anaconda\envs\deathstar
  ```
  As shown in the example above, this clone path may include spaces. This will be particularly common on Windows, where a global install will result in files written to Program Files, which a non-administrator user will not be able to write to, and contains spaces. Because the command presents a prefix, it should be quoted to guard against this case.
  
  
  
  </issue>
  <code>
  [start of conda/cli/help.py]
  1 from __future__ import absolute_import, division, print_function, unicode_literals
  2 
  3 from os.path import join
  4 
  5 from .common import name_prefix
  6 from ..base.context import context
  7 from ..exceptions import CondaIOError
  8 
  9 
  10 def read_message(fn):
  11     res = []
  12     for envs_dir in context.envs_dirs:
  13         path = join(envs_dir, '.conda-help', fn)
  14         try:
  15             with open(path) as fi:
  16                 s = fi.read().decode('utf-8')
  17             s = s.replace('${envs_dir}', envs_dir)
  18             res.append(s)
  19         except IOError:
  20             pass
  21     return ''.join(res)
  22 
  23 
  24 def root_read_only(command, prefix, json=False):
  25     assert command in {'install', 'update', 'remove'}
  26 
  27     msg = read_message('ro.txt')
  28     if not msg:
  29         msg = """\
  30 Missing write permissions in: ${root_dir}
  31 #
  32 # You don't appear to have the necessary permissions to ${command} packages
  33 # into the install area '${root_dir}'.
  34 # However you can clone this environment into your home directory and
  35 # then make changes to it.
  36 # This may be done using the command:
  37 #
  38 # $ conda create -n my_${name} --clone=${prefix}
  39 """
  40     msg = msg.replace('${root_dir}', context.root_prefix)
  41     msg = msg.replace('${prefix}', prefix)
  42     msg = msg.replace('${name}', name_prefix(prefix))
  43     msg = msg.replace('${command}', command)
  44     raise CondaIOError(msg)
  45
  [end of conda/cli/help.py]
  </code>
  
  I need you to solve this issue by generating a single patch file that I can apply directly to this repository using git apply. Please respond with a single patch file in the following format.
  <patch>
  diff --git a/file.py b/file.py
  --- a/file.py
  +++ b/file.py
  @@ -1,27 +1,35 @@
   def euclidean(a, b):
  -    while b:
  -        a, b = b, a % b
  -    return a
  +    if b == 0:
  +        return a
  +    return euclidean(b, a % b)
   
   
   def bresenham(x0, y0, x1, y1):
       points = []
       dx = abs(x1 - x0)
       dy = abs(y1 - y0)
  -    sx = 1 if x0 < x1 else -1
  -    sy = 1 if y0 < y1 else -1
  -    err = dx - dy
  +    x, y = x0, y0
  +    sx = -1 if x0 > x1 else 1
  +    sy = -1 if y0 > y1 else 1
   
  -    while True:
  -        points.append((x0, y0))
  -        if x0 == x1 and y0 == y1:
  -            break
  -        e2 = 2 * err
  -        if e2 > -dy:
  -            err -= dy
  -            x0 += sx
  -        if e2 < dx:
  -            err += dx
  -            y0 += sy
  +    if dx > dy:
  +        err = dx / 2.0
  +        while x != x1:
  +            points.append((x, y))
  +            err -= dy
  +            if err < 0:
  +                y += sy
  +                err += dx
  +            x += sx
  +    else:
  +        err = dy / 2.0
  +        while y != y1:
  +            points.append((x, y))
  +            err -= dx
  +            if err < 0:
  +                x += sx
  +                err += dy
  +            y += sy
  +
  +    points.append((x, y))
       return points
  
  </patch>
golden_diff: diff --git a/conda/cli/help.py b/conda/cli/help.py
  --- a/conda/cli/help.py
  +++ b/conda/cli/help.py
  @@ -35,7 +35,7 @@
   # then make changes to it.
   # This may be done using the command:
   #
  -# $ conda create -n my_${name} --clone=${prefix}
  +# $ conda create -n my_${name} --clone="${prefix}"
   """
       msg = msg.replace('${root_dir}', context.root_prefix)
       msg = msg.replace('${prefix}', prefix)
  
verification_info: {"golden_diff": "diff --git a/conda/cli/help.py b/conda/cli/help.py\n--- a/conda/cli/help.py\n+++ b/conda/cli/help.py\n@@ -35,7 +35,7 @@\n # then make changes to it.\n # This may be done using the command:\n #\n-# $ conda create -n my_${name} --clone=${prefix}\n+# $ conda create -n my_${name} --clone=\"${prefix}\"\n \"\"\"\n     msg = msg.replace('${root_dir}', context.root_prefix)\n     msg = msg.replace('${prefix}', prefix)\n", "issue": "When lacking permissions to write, clone message should quote prefix.\nWhen trying to install a new package into a location that the user lacks write permissions (read-only root), conda helpfully suggests cloning the environment into a new location:\r\n\r\n```\r\nCondaIOError: IO error: Missing write permissions in: C:\\Program Files\\Anaconda\r\n#\r\n# You don't appear to have the necessary permissions to install packages\r\n# into the install area 'C:\\Program Files\\Anaconda'.\r\n# However you can clone this environment into your home directory and\r\n# then make changes to it.\r\n# This may be done using the command:\r\n#\r\n# $ conda create -n my_deathstar --clone=C:\\Program Files\\Anaconda\\envs\\deathstar\r\n```\r\nAs shown in the example above, this clone path may include spaces. This will be particularly common on Windows, where a global install will result in files written to Program Files, which a non-administrator user will not be able to write to, and contains spaces. Because the command presents a prefix, it should be quoted to guard against this case.\r\n\r\n\n", "before_files": [{"content": "from __future__ import absolute_import, division, print_function, unicode_literals\n\nfrom os.path import join\n\nfrom .common import name_prefix\nfrom ..base.context import context\nfrom ..exceptions import CondaIOError\n\n\ndef read_message(fn):\n    res = []\n    for envs_dir in context.envs_dirs:\n        path = join(envs_dir, '.conda-help', fn)\n        try:\n            with open(path) as fi:\n                s = fi.read().decode('utf-8')\n            s = s.replace('${envs_dir}', envs_dir)\n            res.append(s)\n        except IOError:\n            pass\n    return ''.join(res)\n\n\ndef root_read_only(command, prefix, json=False):\n    assert command in {'install', 'update', 'remove'}\n\n    msg = read_message('ro.txt')\n    if not msg:\n        msg = \"\"\"\\\nMissing write permissions in: ${root_dir}\n#\n# You don't appear to have the necessary permissions to ${command} packages\n# into the install area '${root_dir}'.\n# However you can clone this environment into your home directory and\n# then make changes to it.\n# This may be done using the command:\n#\n# $ conda create -n my_${name} --clone=${prefix}\n\"\"\"\n    msg = msg.replace('${root_dir}', context.root_prefix)\n    msg = msg.replace('${prefix}', prefix)\n    msg = msg.replace('${name}', name_prefix(prefix))\n    msg = msg.replace('${command}', command)\n    raise CondaIOError(msg)\n", "path": "conda/cli/help.py"}]}