fs.getDrive
From ComputerCraft Wiki
Revision as of 18:46, 28 November 2012 by AfterLifeLochie (Talk | contribs) (Moved to CAT:LuaCoreFunctions)
Function fs.getDrive | |
Returns the storage medium holding a path, or nil if the path does not exist | |
Syntax | fs.getDrive(string path) |
Returns | string the type of storage medium holding the path, as of ComputerCraft 1.3 one of "rom" or "hdd"[1] |
Part of | ComputerCraft |
API | fs |
Examples
Example | |
Checks that the standard "startup" file is stored in ROM | |
Code |
print(fs.getDrive("rom/startup")) |
Output | rom |