Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adds check for $EDITOR for the annotate command #97

Merged
merged 1 commit into from Jan 1, 2016

Conversation

cash
Copy link
Contributor

@cash cash commented Dec 31, 2015

If $EDITOR is not defined, running annotate results in:

sh: 1: /tmp/tmp2LcDL9: Permission denied
No annotation entered, exiting.

This commit changes that to a helpful error message.

@bilderbuchi
Copy link

This code will most probably fail on Windows as there is no $EDITOR (not your PR, the annotate function as it is).
To make it more robust, on Windows you could use os.startfile to open the file in question with the default application.

@cash
Copy link
Contributor Author

cash commented Jan 1, 2016

@bilderbuchi os.startfile won't wait for termination of the process.

@robintw
Copy link
Contributor

robintw commented Jan 1, 2016

Thanks :-)

I'll merge this PR now, as it definitely improves on the current situation, and I'll add @bilderbuchi's note about Windows as a separate issue.

robintw added a commit that referenced this pull request Jan 1, 2016
adds check for $EDITOR for the annotate command
@robintw robintw merged commit e9bf79f into recipy:master Jan 1, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants