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: export p8s as well as prometheus #31

Open
JeffMelton opened this issue Sep 30, 2024 · 3 comments
Open

feature request: export p8s as well as prometheus #31

JeffMelton opened this issue Sep 30, 2024 · 3 comments

Comments

@JeffMelton
Copy link

Re: this discussion on the nushell repo

Plugins don't seem to be friendly to function-aliases that take spread args, and typing prometheus isn't as cool as typing p8s. Would love to see the plugin export the latter in addition to the former if possible.

Thanks for the plugin in any case! I'm excited to start using it.

@drbrain
Copy link
Owner

drbrain commented Nov 22, 2024

Ugh, I'm not sure about this. Before digging into the details you linked I thought "I'd rather help fix this in nushell", but it seems that's not very easy because of the spread args problem.

It seems that either allowing spread args in the plugin command signatures or exporting a p8s alias would require duplication of each impl SimplePluginCommand. This is reasonable to accomplish with a macro, but I'm not fond of it.

Did you get anywhere with this suggestion to individually alias each command starting with prometheus ?

@JeffMelton
Copy link
Author

No, I didn't even try. 🙃 p8s is one of those things I use in spurts, and I was in one when I bounced this over to you. I'm off on other projects for a while, so it's lower priority. I guess what I'd say is if you can find a way to do it, that would be awesome. If not, no harm done, and I appreciate you looking at it. 😄

@drbrain
Copy link
Owner

drbrain commented Nov 22, 2024

I myself don't use my plugin very often, and often rely on tab-completion to remember the arguments. I'll leave it open for a while as a reminder to see if there's a way to do this easier than what nushell currently offers.

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