You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 13, 2018. It is now read-only.
Some other tools such as the Sphinx document generator implements a cache process that avoid rebuilding every time every file if some remain unchanged, since GSL doesnt have any caching process, that results in creating again and again every time the same files without checking if files were even been changed, that why I hacked a little caching system that only operates at GSL post-processing stage, once files are generated. It will be nice to see such a feature as another built-in GSL class.
Basically, the following functions can be used in-place of the usual .output.close GSL directives:
Some other tools such as the Sphinx document generator implements a cache process that avoid rebuilding every time every file if some remain unchanged, since GSL doesnt have any caching process, that results in creating again and again every time the same files without checking if files were even been changed, that why I hacked a little caching system that only operates at GSL post-processing stage, once files are generated. It will be nice to see such a feature as another built-in GSL class.
Basically, the following functions can be used in-place of the usual
.output
.close
GSL directives:cache_open(FILENAME [, FILEPATH [, BUILDDIR [, CACHEDIR ] ] ] ) -> FILE_CACHED
cache_close(FILE_CACHED [, BUILDDIR [, CACHEDIR ] ] )
that use the
samefiles(f1, f2)
function in order to compare the content of two files thanks to thefile.slurp
andstring.hash
builtin functions.Here is a basic usage of these functions:
Calling this code twice will only create the
build/helloworld.txt
once while thebuild/.cache/helloworld.txt
will be built twice.And here is source code:
The text was updated successfully, but these errors were encountered: