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

EDITOR with space #80

Closed
lengyijun opened this issue Oct 16, 2020 · 3 comments
Closed

EDITOR with space #80

lengyijun opened this issue Oct 16, 2020 · 3 comments

Comments

@lengyijun
Copy link

lengyijun commented Oct 16, 2020

$ echo $EDITOR
vim -N -u NONE

$ RUST_BACKTRACE=1 the-way new                                                                                                                                               
✔ Description · cgo
✔ Language · go
✔ Tags (space separated) · 
✔ Code snippet (<RET> to edit in external editor) · 
Error: 
   0: No such file or directory (os error 2)

  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ BACKTRACE ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
                                ⋮ 2 frames hidden ⋮                               
   3: the_way::utils::external_editor_input::hcbbab1d7fe9610eb
      at <unknown source file>
   4: the_way::the_way::snippet::Snippet::from_user::h807f2b0215308756
      at <unknown source file>
   5: the_way::the_way::TheWay::run::hc7651f9367a8cabe
      at <unknown source file>
   6: the_way::the_way::TheWay::start::hdaa9914ca7162356
      at <unknown source file>
   7: the_way::main::h54fb7cb483b9714d
      at <unknown source file>
   8: std::sys_common::backtrace::__rust_begin_short_backtrace::h1d6ae41c2286663c
      at <unknown source file>
   9: std::rt::lang_start::{{closure}}::h55da07d914c978cf
      at <unknown source file>
  10: core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::h5867dc20a6af6cac
      at /rustc/c71248b70870960af9993de4f31d3cba9bbce7e8/library/core/src/ops/function.rs:259
  11: std::panicking::try::do_call::h32e8dcce59f53a45
      at /rustc/c71248b70870960af9993de4f31d3cba9bbce7e8/library/std/src/panicking.rs:381
  12: std::panicking::try::h7d7b073280e6de2f
      at /rustc/c71248b70870960af9993de4f31d3cba9bbce7e8/library/std/src/panicking.rs:345
  13: std::panic::catch_unwind::h801333b3e4e7d79f
      at /rustc/c71248b70870960af9993de4f31d3cba9bbce7e8/library/std/src/panic.rs:382
  14: std::rt::lang_start_internal::h2c157bf657c6892a
      at /rustc/c71248b70870960af9993de4f31d3cba9bbce7e8/library/std/src/rt.rs:51
  15: main
      at <unknown source file>
  16: __libc_start_main
      at <unknown source file>
  17: _start
      at <unknown source file>

Suggestion: Set your default editor using the $EDITOR or $VISUAL environment variables

Run with COLORBT_SHOW_HIDDEN=1 environment variable to disable frame filtering.
Run with RUST_BACKTRACE=full to include source snippets.

This is a bug in console-rs/dialoguer#87

@Ninjani
Copy link
Member

Ninjani commented Oct 16, 2020

Thanks for the issue and the fix @lengyijun ! I'll push a new release as soon as dialoguer does

@lengyijun
Copy link
Author

I feel that it require more tests on mac and windows before updating dialoguer dependency.

@Ninjani
Copy link
Member

Ninjani commented Oct 18, 2020

Works on Mac with the new release so I'll go ahead and update!

(Fixed in v0.10.1)

@Ninjani Ninjani closed this as completed Oct 18, 2020
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

No branches or pull requests

2 participants