AltME: SDK

Messages

Ladislav
I use this form frequently:
REBOL [
    file: %myscript.r
]
    #include %lib/a.r
    #include %lib/b.r
    app: context [...]
    app/run
and evaluate it as follows:
include %myscript.r
also, this form is directly encappable
DocKimbel
The include system I use for all my apps that need to be encapped allows me to do this:
    # rebol -s %cheyenne.r
and
    # encap %cheyenne.r
Can INCLUDE provide similar feature? If yes, how can it be achieved in the easiest way? If not, what is the closest option INCLUDE can provide me?
Ladislav
Yes, that is very similar to what I use here
DocKimbel
Ladislav: in your above form, how do you deal with READ calls (for reading data files) in the application?
Ladislav
reading data files in the application? - you mean to be "in the application"?
(when encapped?)
DocKimbel
Both cases, when run and encapped.
Ladislav
yes, it is always both
DocKimbel
I mean, when encapped, such data file should be encapped too.
Ladislav
I can use either #include-binary or #include-string, etc. directives, or even the #do directive for something different
DocKimbel
When run with DO, it should be just read from disk.
Ladislav
it works using something like
# rebol -s %incl.r "%cheyenne.r"
actually, I do not write these #rebol -s %incl.r "...", I just click on the file
and to encap it, I use right-click
...and it does not work just in Windows, the same holds for Linux
DocKimbel
I run all my REBOL scripts using F10 key from my code editor (which launches "rebol -s" on the script), having to use a wrapper script won't fit well my way of working. F11 encaps the current script directly with /Pro, F12 encaps it with /CommandView. :-)
Ladislav
that is not a problem, why there is any problem in using rebol -s %incl instead of rebol -s?
DocKimbel
I guess I shouldn't be able to use %do on any such script from console anymore?
sorry: do instead of %do
Ladislav
just use INCLUDE

Last message posted 6 weeks ago.