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

Feature request: Better exit-code based experience? #351

Open
dgollahon opened this issue Apr 28, 2023 · 5 comments
Open

Feature request: Better exit-code based experience? #351

dgollahon opened this issue Apr 28, 2023 · 5 comments

Comments

@dgollahon
Copy link

Hi,

Thank you for a wonderful tool. One frustration I have is I often auto-complete a known-failing command. Would it be possible to improve the UX of this? Ideas I had:

  1. color recently failing commands in red (or otherwise mark them in some way)
  2. have an option to always sort failing commands below non-failing commands
  3. try to somehow recognize when something has failed for a specific reason/when it can't even run? i'm not sure if there's a reasonable way to do this, especially across shells, but I really care about this for cases like when I typo git as gti or something similar to that. I often run commands that might reasonably have a failing status sometimes but I really don't want to rerun commands that are very, very unlikely to pass like typos. If it's a command not found: ... I wish I could exclude it. I did notice there's a cmd_tpl normalization in the sqlite db--I wonder if that could be used to find out if the command could possibly be in the path..?
  4. record if the command has only failed and weight that lower? so if I run make test or something and it fails some of the time, it shouldn't necessarily be penalized but gti will never ever pass.

If I have a clear idea of what you would support or recommend I'd be happy to try and send a PR if that's welcome/helpful.

Thanks!

@dgollahon
Copy link
Author

Oh, and one more thought/possible feature: allow deleting without confirmation. I think if I could just hit F2 or some keystroke without having to then confirm with y it would be easier to remove commands I don't want anymore.

@cantino
Copy link
Owner

cantino commented May 5, 2023

Hey @dgollahon, thanks for the suggestions!

There is a MCFLY_DELETE_WITHOUT_CONFIRM environment option already.

I like the idea of coloring failing commands (or maybe only always failing commands?) differently. Would you want to work on this?

@dgollahon
Copy link
Author

There is a MCFLY_DELETE_WITHOUT_CONFIRM environment option already.

Oh, great. Should that be added to the README? Or is there a different place for extended docs? I'm not sure how I would have discovered that.

Would you want to work on this?

Yeah, I would be interested. I'm not sure exactly when I can do it but would be happy to try at some point.

@cantino
Copy link
Owner

cantino commented Jun 3, 2023

Fixed in db63e4b, thanks!

@cantino cantino closed this as completed Jun 3, 2023
@cantino cantino reopened this Jun 3, 2023
@cantino
Copy link
Owner

cantino commented Jun 3, 2023

Didn't mean to close the issue, since your color-coding of failing commands is still a good idea.

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