From ComputerCraft Wiki
Revision as of 04:00, 12 March 2012 by Hawk777 (Talk | contribs) (Create page)

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Grid Redstone.png  Function fs.getName
Returns the last path component (forward-slash-separated) component of a path (which need not exist)
Syntax fs.getName(string path)
Returns string the last path component of the path, or the string "root" if the path refers to the root directory
Part of ComputerCraft
API fs


Grid paper.png  Example
Gets the last path component of a file
Output colors