Ueli: Shortcuts: Additional Arguments for selfmade Script in Shortcuts

Created on 14 Feb 2020  路  6Comments  路  Source: oliverschwendener/ueli

First of all: Thank you! I love ueli, it makes my life so much easier.

I use a lot of self made scripts (mostly python). I open the Scripts using Shortcuts type: Comandline. It would be awesome to be able to call the script and giving it addtional Arguments.

example: This script takes two arguments

C:\users\me\.\pythonscript.pyw --ID:1002 --Name:Jon

Defining it in ueli:

C:\users\me\.\pythonscript.pyw --ID:{{arg[0]}} --Name:{{arg[1]}}

And then calling the Shortcut in ueli with:

myshortcut 1002 Jon

Again, Love your work. Thanks.

enhancement feature request

Most helpful comment

Indeed this is a fantastic work.

I think I have the same request, not for _script_, but for _application_. Thus I leave a comment here rather than open a new issue.

Here is the detail:

ueli has the everything plugin to pass the query to es.exe and the web search plugin to search in browser. Thus, I think it work the same if run some other apps.

So I try to locate goldendict.exe on the setting page of everything, and use es?[word] on ueli. It turn out to work fine.

input: es?test

it work the same as directly execute:

C:\...\GoldenDict.exe test

Many applications accept arguments even though they don't provide command-line interface, so I think this feature will be great.

Thanks again馃槉

All 6 comments

Indeed this is a fantastic work.

I think I have the same request, not for _script_, but for _application_. Thus I leave a comment here rather than open a new issue.

Here is the detail:

ueli has the everything plugin to pass the query to es.exe and the web search plugin to search in browser. Thus, I think it work the same if run some other apps.

So I try to locate goldendict.exe on the setting page of everything, and use es?[word] on ueli. It turn out to work fine.

input: es?test

it work the same as directly execute:

C:\...\GoldenDict.exe test

Many applications accept arguments even though they don't provide command-line interface, so I think this feature will be great.

Thanks again馃槉

I would love this. It seems like something like this used to be possible with customCommands (#50).

This would be really great. I used wo have a shortcut for "jira xxx-3123" which opened my local jira instance with the argument[0] as ticket. Maybe just allow a regex to be used as the "command"?
So in my case it would be:
Type: Url
Name: jira
Url: https://my.jira/jira/browse/{0}
NEW Field: Parameter Regex: (.*)
So this would then parse the whole argument string with the given regex and replace the placeholders in the url/command with the according capture groups before executing. This way you could even use multiple parameters.

I just found out for my scenario, I can use the "Web search" plugin.

Great idea and very useful feature, especially in terms of using argument with applications as hwongbaul mentioned above

I'm also interested in this feature!
Thank you for your awesome work!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

gabriel-peracio picture gabriel-peracio  路  3Comments

walter6469 picture walter6469  路  6Comments

moses-bowman picture moses-bowman  路  3Comments

oliverschwendener picture oliverschwendener  路  3Comments

pbuw picture pbuw  路  5Comments