ish-app / ish

Linux shell for iOS
https://ish.app
Other
17.05k stars 901 forks source link

Feature Request: URL Scheme #260

Open nshoo opened 5 years ago

nshoo commented 5 years ago

It would be really nice to be able to open iSH from other apps using a url scheme. It doesn’t even have to perform actions in the app, just being able to open iSH would be great and enable a lot of automation.

tbodt commented 5 years ago

A URL scheme doesn't seem all that useful to me if it does nothing beyond opening the app...

francoisvignon commented 5 years ago

maybe starting the command specified in the url ? if started by url run the specified command and if not run the command from settings ...

tbodt commented 5 years ago

The only way to control whether it runs the command in the url or not would be to close the app from the switcher.

francoisvignon commented 5 years ago

ok


Francois

Le 8 janv. 2019 à 15:53, Theodore Dubois notifications@github.com a écrit :

The only way to control whether it runs the command in the url or not would be to close the app from the switcher.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/tbodt/ish/issues/260#issuecomment-452326150, or mute the thread https://github.com/notifications/unsubscribe-auth/ArnvUhrrYNvTtGPYwRoBy3X_OIdnJNsyks5vBLD0gaJpZM4Z0sTt.

nshoo commented 5 years ago

The use case I had in mind was being able to run programs from an external code editor inside of iSH. This would be possible with just the ability to open the app. With some clever use of a .profile script a program could be sent to iSH automatically, upon opening, by some 3rd party automation app like Pythonista. Another step up would be the ability to open another app from ish with a shell command, but that’s a lot more work. I’m imagining ish as a way to connect Linux programs into scripts I already have on my phone. I’ll admit this is all really low priority stuff, but I find the automation aspect appealing. Thanks!

nshoo commented 5 years ago

I should mention that the end goal would be some kind of iOS shortcuts integration, but that’s a long way down the road.

yonika commented 5 years ago

https://github.com/tbodt/ish/issues/268

• iOS X callback and URL Scheme to run a shell command with arguments can be very very useful. • With SIRI Shortcuts it can be used to run a bash / Perl / python script with command line arguments. • X-callback also allows the called app to return a to the calling app with a success / error / canceled value. • This would open a world of options to use this app

An example use of url scheme for such a thing is in Pythonista. The following is a url I use with x-callback in shortcuts to run a script in Pythonista- pythonista3://switcher.py?action=run&args=-mget_state

To call back to the shortcuts app from Pythonista- I use the following in my python script: app = UIApplication.sharedApplication() app.openURL_(nsurl('shortcuts://x-success'))

francoisvignon commented 5 years ago

I think starting a session by url scheme will be easy to setup once PTS was implemented.

before it seem difficult, because you cannot start a new sesson if qlready ine is in progress.

ProjectZeroDays commented 4 years ago

The use case I had in mind was being able to run programs from an external code editor inside of iSH. This would be possible with just the ability to open the app. With some clever use of a .profile script a program could be sent to iSH automatically, upon opening, by some 3rd party automation app like Pythonista. Another step up would be the ability to open another app from ish with a shell command, but that’s a lot more work. I’m imagining ish as a way to connect Linux programs into scripts I already have on my phone. I’ll admit this is all really low priority stuff, but I find the automation aspect appealing. Thanks!

Now with "opener" you can open iSH and even set a shortcut to do using location time and intricate triggers using Launchcuts, autocuts, toolbox pro, and even notifications and batch actions together in the background with Pushcuts, and idroplinks allows many of these actions to happen even easier. If you do discover something useful and interesting with this please reach out to me on discord or here as I'm building a custom preconfigured setup and would like to setup a shortcut for this very reason. There are shortcuts that can clone git repos and many more I'm willing to share everything I have if you reach out.

semaja2 commented 4 years ago

Would be great to run commands via a URL param, my use case is with RoyalTSi and being able to open a SSH session using iSH

dgarner-cg commented 1 year ago

Bro, 4 fucking years and no response to this? Wow.

dougpagani commented 1 year ago

Bro, 4 fucking years and no response to this? Wow.

It's FOSS, you're owed nothing. And entitled as you are, you're even less likely to get it. Be thankful for ish even existing. If you want it so bad, learn C and submit a pull request. Most of the hard work of even setting up for it has already been done. I would be SOL if i tried to implement a bunch of syscalls/x86 instructions.

I'd love the feature too but why get mad over something I have done no work to deserve in any way? Don't be a dick.

dgarner-cg commented 1 year ago

Bro, 4 fucking years and no response to this? Wow.

It's FOSS, you're owed nothing. And entitled as you are, you're even less likely to get it. Be thankful for ish even existing. If you want it so bad, learn C and submit a pull request. Most of the hard work of even setting up for it has already been done. I would be SOL if i tried to implement a bunch of syscalls/x86 instructions.

I'd love the feature too but why get mad over something I have done no work to deserve in any way? Don't be a dick.

Sorry if I got sand in your vagina, sir. Can I help you rid yourself of the irritation?

saagarjha commented 1 year ago

We appreciate that people are passionate about features that are important to them, but we also ask that the conversation remain civil. Please keep discussion on-topic and cordial when talking about this feature or its implementation timeline.

plia7 commented 8 months ago

@tbodt Could you please add it? It's very useful to run commands with it through the Shortcuts app. It's super useful and the options are unlimited what can be done with it.

The idea is to have an iOS URL scheme where you can pass the command you want to execute, not just open the app.

For example:

ish://run?command=echo test

This will result in opening the iSH app and executing the echo test command with the test output.

Or alternatively, you could have a parameter that will execute a specific file:

ish://run?file=script123

This will open the iSH app and execute the file script123.

Thank you.