Giter Site home page Giter Site logo

Comments (6)

mitsuhiko avatar mitsuhiko commented on August 25, 2024

To the best of my knowledge EDITOR does not support arguments. If you can point me to a piece of documentation that claims otherwise please reopen this issue.

from click.

untitaker avatar untitaker commented on August 25, 2024

afaik kabniel is not able to reopen the issue once you close it, @mitsuhiko

from click.

untitaker avatar untitaker commented on August 25, 2024

I believe i have seen the presence of arguments in the EDITOR variable several times when reading through the documentation of Linux distribution. I believe this is similar to the situation with shebangs. However, is there a reason why it should not be allowed? I am aware that the splitting of such a value goes beyond str.split(), but it still shouldn't be too hard.

from click.

mitsuhiko avatar mitsuhiko commented on August 25, 2024

Because the behavior is different. If EDITOR accepts arguments then the editor name needs quoting if it's installed into a folder with whitespace which is very common on windows (C:\Program files).

from click.

mitsuhiko avatar mitsuhiko commented on August 25, 2024

I changed that now as this is apparently what git and hg do.

from click.

dufferzafar avatar dufferzafar commented on August 25, 2024

Has this been fixed? I'm facing a similar issue when I try to use VS Code as my editor:

>>> click.edit(editor='code-insiders -w')

/bin/sh: code-insiders -w: command not found

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib/python3.8/site-packages/click/termui.py", line 587, in edit
    return editor.edit(text)
  File "/usr/lib/python3.8/site-packages/click/_termui_impl.py", line 497, in edit
    self.edit_file(name)
  File "/usr/lib/python3.8/site-packages/click/_termui_impl.py", line 472, in edit_file
    raise ClickException("{}: Editing failed!".format(editor))
click.exceptions.ClickException: code-insiders -w: Editing failed!

from click.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.