Jump to content




multishell access


  • You cannot reply to this topic
6 replies to this topic

#1 Hiran

  • Members
  • 44 posts

Posted 07 October 2014 - 11:13 AM

By default you dont have access to multishell in new tabs so running
multishell.launch({},"rom/programs/lua")
and in new tab
print (shell)
print (multishell)
will both show nil

Should i change it so that you would have access to both apis from anywhere, or only my parent shell should be able to create etc new shells?

edit:

I know that i can pass them with first parameter, but i want to know if i should make it default.

Edited by Hiran, 07 October 2014 - 11:19 AM.


#2 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 7,099 posts
  • LocationTasmania (AU)

Posted 07 October 2014 - 11:38 AM

I'd say that access to shell is pretty important for quite a few scripts. multishell, not so much, but I don't see why you'd want to block it.

#3 Hiran

  • Members
  • 44 posts

Posted 07 October 2014 - 12:19 PM

theyre blocked by default, and im asking if i should unlock them :)

edit:

if you use:
multishell.launch({},"rom/programs/shell")
and then enter lua you will see shell table, but multishell will still be inaccessible.

Edited by Hiran, 07 October 2014 - 12:21 PM.


#4 Bomb Bloke

    Hobbyist Coder

  • Moderators
  • 7,099 posts
  • LocationTasmania (AU)

Posted 07 October 2014 - 12:32 PM

View PostHiran, on 07 October 2014 - 12:19 PM, said:

theyre blocked by default, and im asking if i should unlock them :)

Not so much "blocked" as "just not included". I'm saying your best bet is to provide them unless you can specifically think of a good reason not to - for example, if you've coded up your own replacements with which you wish to fill the gap.

#5 MKlegoman357

  • Members
  • 1,170 posts
  • LocationKaunas, Lithuania

Posted 07 October 2014 - 01:05 PM

I would say leave it as it is. Actually, you could make something like 'multishell.run(program, arguments...)' which could work like 'shell.run()' passing shell and multishell APIs to the program.

#6 Hiran

  • Members
  • 44 posts

Posted 07 October 2014 - 03:06 PM

Im thinking of making something more gui-like, so ill probably go with Bomb Bloke advice and force-include them in every shell.
Making my own replacements isnt a good idea, as it will conflict with programs not created by me, and i want to reduce conflicts by as much as i can.

#7 natedogith1

  • Members
  • 110 posts

Posted 07 October 2014 - 09:47 PM

Is there a reason you're using multishell.launch instead of shell.openTab ?





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users