Bug 1467077 - sensible-editor calls 'which' without any parameters (prints use info of which)
Summary: sensible-editor calls 'which' without any parameters (prints use info of which)
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: sensible-utils
Version: 26
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Sandro Mani
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-07-02 12:59 UTC by Hedayat Vatankhah
Modified: 2017-07-27 21:52 UTC (History)
1 user (show)

Fixed In Version: sensible-utils-0.0.9-6.fc26 sensible-utils-0.0.9-6.fc24 sensible-utils-0.0.9-6.fc25
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-07-27 16:52:08 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Hedayat Vatankhah 2017-07-02 12:59:12 UTC
Description of problem:
When running sensible-editor (directly or via debchange) it prints usage guide for which, which is because of running commands like 'which $EDITOR' when EDITOR is not set. 
It doesn't happen in Debian/Ubuntu because they use a different implementation of which, which doesn't complain when run without any parameters. But in Fedora, if you run which with no parameters, its full usage guide is printed, which is annoying.

I suggest redirecting which's stderr to /dev/null at these initial lines like below:

[ "$(which $EDITOR 2> /dev/null || true)" = "$p" ] && EDITOR=
[ "$(which $VISUAL 2> /dev/null || true)" = "$p" ] && VISUAL=
[ "$(which $SELECTED_EDITOR 2> /dev/null || true)" = "$p" ] && SELECTED_EDITOR=

Comment 1 Fedora Update System 2017-07-14 10:02:45 UTC
sensible-utils-0.0.9-6.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2017-003dabb204

Comment 2 Fedora Update System 2017-07-14 19:53:03 UTC
sensible-utils-0.0.9-6.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-003dabb204

Comment 3 Fedora Update System 2017-07-14 20:27:00 UTC
sensible-utils-0.0.9-6.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-444ad737fd

Comment 4 Fedora Update System 2017-07-14 22:56:58 UTC
sensible-utils-0.0.9-6.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-f0c6e7b0c3

Comment 5 Fedora Update System 2017-07-27 16:52:08 UTC
sensible-utils-0.0.9-6.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.

Comment 6 Fedora Update System 2017-07-27 19:50:19 UTC
sensible-utils-0.0.9-6.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

Comment 7 Fedora Update System 2017-07-27 21:52:26 UTC
sensible-utils-0.0.9-6.fc25 has been pushed to the Fedora 25 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.