Legacy stack woes
J. Landman Gay
jacque at hyperactivesw.com
Tue Jun 5 13:59:10 EDT 2007
Rob Cozens wrote:
> Hi All,
>
> In setting up an SDBII demo for interested parties I have run into the
> need to distribute stacks in Legacy format so the software can be used
> by Linux developers.
>
> Working in RRv2.7+ and building distribution downloads in Legacy format
> cries out for: developers' handlers to:
>
> 1. Identify the format of a stack (AFAIK, the SmartProperties plugIn
> will not retrieve stack properties, and lacking the list of properties
> by object available in pre-v2.7 docs, I don't even know the name of the
> stack property designating Legacy or v2.7+ format. Without this
> capability, I have to open each stack I save in Legacy format in v2.7+
> with an older version of RunRev that will throw an error if the format
> is not Legacy.)
I don't think there is such a property, but you can read the binary file
to see the format. If it starts with "REVO" then it is the new format.
But for what you are doing, I don't think you'll have to resort to this.
>
> 2. Save a stack in Legacy format, specifying an extension other than
> ".rev" (Three of Serendipity's four proprietary file types remain in
> stack format. Every time I save those stacks in Legacy format, I must
> subsequently rename them to remove ".rev".)
Go to preferences, "Files and memory" pane, and turn off the option that
automatically adds the ".rev" extension. Also turn on the option in the
same pane that preserves the stack file type when saving a legacy stack.
>
> 3. Save multiple stacks in Legacy format without having to reset the
> "Save as type" popUp every time.
I think a script would be the easiest way for the initial stack
creation. For a single file:
on mySave
set the stackfileversion to "2.4"
save this stack as <myFileName>
end mySave
Or wrap this in a loop that saves all the open stacks, or a list of
stacks you pass as a parameter, or however else you need to do it. The
stackfileversion property is global, so you only need to set it once.
You could even do it in the message box before issuing a "save" command
from a script.
If the Rev preference is set to respect legacy stacks, you don't need to
run a script at all after the stack has been saved the first time. Cmd-S
will just work.
--
Jacqueline Landman Gay | jacque at hyperactivesw.com
HyperActive Software | http://www.hyperactivesw.com
More information about the use-livecode
mailing list