mirror of
https://github.com/SquidDev-CC/CC-Tweaked
synced 2025-10-23 09:57:39 +00:00
Add fs.getCapacity and fs.attributes (#365)
- fs.getCapacity just returns the capacity of the current drive, if available. This will be nil on rom mounts. - fs.attributes returns an lfs like table of various file attributes. Currently, this contains: - access, modification, created: When this file was last accessed, modified and created. Time is measured in milliseconds since the epoch, same as os.epoch("utc") and what is accepted by os.date. - size: Same as fs.getSize - isDir: same as fs.isDir Closes #262
This commit is contained in:
@@ -79,7 +79,7 @@ public class ComputerTestDelegate
|
||||
ComputerCraft.log = LogManager.getLogger( ComputerCraft.MOD_ID );
|
||||
|
||||
Terminal term = new Terminal( 78, 20 );
|
||||
IWritableMount mount = new FileMount( new File( "test-files/mount" ), Long.MAX_VALUE );
|
||||
IWritableMount mount = new FileMount( new File( "test-files/mount" ), 10_000_000 );
|
||||
|
||||
// Remove any existing files
|
||||
List<String> children = new ArrayList<>();
|
||||
|
Reference in New Issue
Block a user