Skip to content

Tips and Tricks

ScriptBuilder edited this page Jan 18, 2021 · 18 revisions

Tips And Tricks

Correcting Block after entering and error or Just changing block

Example:
begin
  dim a as string = "test string"
  for i as integer = 0 to a.leg
    print a[i];;
    next
  end

Now there is an obvious error above a.leg, You don't have to retype it
just enter:
edit
by it's self. From here you can edit/change this block. The block will be executed
as soon as you save and quit the editor. If you want to save this block permanently
just change the name during the save phase.

When you installed gsh, both a nanorc and vim/vi rc where installed
so the code should be highlighted.
to choose your editor set the $editor global variable
$$editor="/usr/bin/vi" 
or
$$editor="/bin/nano"
The default editor is nano, to make your choice permanent you need to add it to the
~/.gshrc file
By the way you can edit any, sub/class/struct/variable in gsh

Clone this wiki locally