OpenBoot 2.x Command Reference Manual

Activating an NVRAMRC File

Use the following steps to activate an NVRAMRC command file:

  1. At the ok prompt, type nvedit

    Edit the contents of NVRAMRC using editor commands.

  2. Type Control-C to get out of the editor and back to the ok prompt.

  3. Type nvstore to save your changes.

  4. Enable the interpretation of NVRAMRC by typing: setenv use-nvramrc? true

  5. Type reset to reset the system and execute the NVRAM contents, or type nvramrc eval to execute the contents directly. If you have not yet typed nvstore to save your changes, type nvrun to execute the contents of the temporary edit buffer.

The following example shows you how to create a simple colon definition in NVRAMRC.


ok nvedit 
0: : hello ( -- ) 
1: ." Hello, world. " cr 
2: ; 
3: ^-C 
ok nvstore 
ok setenv use-nvramrc? true 
ok reset 
....
ok hello 
Hello, world.
ok 

Notice the nvedit line number prompts (0:, 1:, 2:, 3:) in the above example. These prompts may be different on some systems.