The
vocabs.refresh vocabulary implements automatic reloading of changed source files.
With the help of the
io.monitors vocabulary, loaded source files across all vocabulary roots are monitored for changes on disk.
If a change to a source file is detected, the next invocation of
refresh-all will compare the file's checksum against its previous value, reloading the file if necessary. This takes advantage of the fact that the
source-files vocabulary records CRC32 checksums of source files that have been parsed by
The parser.
Words for reloading source files:
refresh ( prefix -- )
refresh-all ( -- )