Load

From MiniScript Wiki
Revision as of 03:55, 20 January 2021 by JoeStrout (talk | contribs) (Created page with "In Mini Micro, the <c>load</c> command loads a program into memory from disk. Syntax: load ''path'' This replaces the current program in memory with the MiniScript fi...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

In Mini Micro, the load command loads a program into memory from disk. Syntax:

 load path

This replaces the current program in memory with the MiniScript file at path. Caution: any unsaved changes in your previous program are lost without warning.

The path may be a full (absolute) path, or a partial path relative to the current working directory.  Note that the file extension (.ms) is optional in both save and load.

Example

The following loads theMatrix.ms located in the /sys/demo directory on the system disk, and then runs it.

load "/sys/demo/theMatrix"
run