awsm.fish
awsm.fish copied to clipboard
Add magic-enter plugin
Added Magic-Enter to the plugin list. For OMZ users, this is the fish version of this plugin: https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins/magic-enter
where is the fish version?
@BarbzYHOOL https://github.com/mattmc3/magic-enter.fish
@BarbzYHOOL https://github.com/mattmc3/magic-enter.fish
thanks i'm dumb, proof that i didn't code for a long time This is an interesting plugin idea, the command to run should be configurable though
btw how did you get that notification about my comment?
It's absolutely configurable. Just write your own magic-enter-cmd function:
function magic-enter-cmd --description "Print the command to run when no command was given"
if command git rev-parse --is-inside-work-tree &>/dev/null
echo "echo TODO: git command here"
else
echo "echo TODO: command here"
end
end
you mean rewrite the function inside the plugin file?
No, in your own fish functions directory. It's the same way you would override any function in fish - for example, similar to how you customize your fish_prompt.
Hey Matt! I do think this might be useful, but not sure how yet. The documentation could use some refining before we move forward. Not sure if I'd use this just to run ls
with each enter, but there might be potential for more. Thanks for working on this! Keeping this open for now.
Hello Jorge - as always, thank you - you're absolutely right that this plugin needed a bit more in the README. I've enhanced it - let me know if there's anything else I can do to make it clearer/more useful. It's one of my favorite simple OMZ plugins, so having a similar one in Fish has been a must-have.