read_datablock() reads any comment block of data embedded in the currently
running or edited script or in a given file.
Such an all-in-one script.sce file contains
* Scilab instructions, usually at the head of the script.sce file
* multiline comment blocks /* ... */ containing data that you wish
to read and use in the instructions.
This solution is very portable:
* Data do not need to be stored in any separate external files. Thus, the
script.sce file can be distributed as is to work. No need to build a zip archive
bundling the script and data files together.
* There is no path of external data files to manage in the script. You
don't even have to provide the path of your script.sce file to read the
data.
* Processing instructions and (possibly bulky) data can be clearly separated,
remaining in the same file. This avoids obfuscating the code with data.
* The script.sce file can be printed out in one go, to document your work.
User manual (PDF)
-----------------
English: https://atoms.scilab.org/toolboxes/read_datablock/1.0/files/read_datablock.pdf
INSTALLATION WARNING
--------------------
If on Windows as a not-full-admin you encounter the bug 16961 [1]
| Installation failed! |
|atomsInstall: Error while creating the directory '..dir path..'.|
then installing the module in user mode will work:
--> atomsInstall("read_datablock", "user")
[1]
https://gitlab.com/scilab/scilab/-/issues/16961
https://gitlab.com/scilab/scilab/-/merge_requests/295#note_1653385985