Jump to content




Starting programs anywhere


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

#1 svdragster

  • Members
  • 222 posts
  • LocationGermany

Posted 14 March 2013 - 07:31 AM

Hello,

I want a program to start in a folder called "/svdragster/programs/" anywhere where I type its name, like CraftOS programs.
Is that possible, or do I need to make a fake shell :P

#2 JokerRH

  • Members
  • 147 posts

Posted 14 March 2013 - 07:50 AM

shell.run("/svdragster/programs/whatever")
or
os.loadAPI( "/svdragster/programs/whatever"),
if I recall correctly.

#3 Lyqyd

    Lua Liquidator

  • Moderators
  • 8,465 posts

Posted 14 March 2013 - 07:58 AM

You'll want to look into shell.setPath.

#4 svdragster

  • Members
  • 222 posts
  • LocationGermany

Posted 15 March 2013 - 05:13 AM

shell.setPath(shell.getPath()..":"..("/svdragster/programs"))

doesn't work, attempt to call nil

#5 theoriginalbit

    Semi-Professional ComputerCrafter

  • Moderators
  • 7,332 posts
  • LocationAustralia

Posted 15 March 2013 - 05:31 AM

shell.path not shell.getPath ... got to love inconsistent method names :P

#6 svdragster

  • Members
  • 222 posts
  • LocationGermany

Posted 15 March 2013 - 05:41 AM

View PostTheOriginalBIT, on 15 March 2013 - 05:31 AM, said:

shell.path not shell.getPath ... got to love inconsistent method names :P

:3 thanks





2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users