Difference between revisions of "Shell.setDir"

From ComputerCraft Wiki
Jump to: navigation, search
(Created page with "{{NeedsWork|Function is added, I'll expand tommorow when I can test ingame. basically, the page needs expanding. It will be tagged until I can finish it. ~~~~}} {{Function |...")
 
m (Category operation: +Category:API_Functions)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{NeedsWork|Function is added, I'll expand tommorow when I can test ingame. basically, the page needs expanding. It will be tagged until I can finish it. [[User:Jonjon1234|Jonjon1234]] 16:36, 9 December 2012 (MSK)}}
 
 
 
{{Function
 
{{Function
 
  |name=shell.setDir
 
  |name=shell.setDir
 
  |args=[[string]] directory
 
  |args=[[string]] directory
  |api=she'll
+
  |api=shell
 
  |returns=[[nil]]
 
  |returns=[[nil]]
 
  |addon=ComputerCraft
 
  |addon=ComputerCraft
  |desc=Sets the running directory.
+
  |desc=Sets the working directory.
  |examples=Examples go here (use [[Template:Example]])
+
  |examples={{Example
 +
|desc=Sets the directory.
 +
|code=shell.setDir("rom")
 +
|output=rom> _ (Set to rom)
 +
}}
 +
 
 
  |notes=
 
  |notes=
* Note 1
+
* It does not output anything, it just sets the working directory.
* Note 2
+
 
  }}
 
  }}
 +
 +
[[Category:API_Functions]]

Latest revision as of 05:07, 20 May 2013

Grid Redstone.png  Function shell.setDir
Sets the working directory.
Syntax shell.setDir(string directory)
Returns nil
Part of ComputerCraft
API shell

Examples

Grid paper.png  Example
Sets the directory.
Code
shell.setDir("rom")
Output rom> _ (Set to rom)

Additional Notes

  • It does not output anything, it just sets the working directory.