Loading ...
Sorry, an error occurred while loading the content.
 

Re: [jasspa] Variables

Expand Messages
  • Jon Green
    ... Yep, the variable maximum length is 1024 bytes. I did a ... Yep, this is the correct way to do it.
    Message 1 of 2 , Sep 11, 2005
      Gadrin wrote:
      > I was able to create a "Handsoff.emf" file and use it as the
      > @startup file to initiate an emacs session, do some editing write a
      > new file and exit.
      >
      > It seems variables can hold up to about 1K of data.

      Yep, the variable maximum length is 1024 bytes.

      I did a
      >
      > shell-command "dir /s > dir.txt"
      >
      > then had EMACS grab the file and copy it line by line using &cat
      > to a variable. then at the EOF find a new buffer then
      > insert-string %dirtxt (which was my variable). It was able to hold
      > about 22 lines of data before it couldn't add more. (no errors, just
      > further &cat's did nothing).
      >
      > I ended up changing the script so that it simply inserted each line
      > into a temp buffer each iteration, before saving. The temp buffer
      > held the path (parsed from "Directory of ") and the filename on each
      > line (minus the extraneous data). Worked great.

      Yep, this is the correct way to do it.

      >
      > I also found that using
      >
      > execute-file "me.emf"
      >
      > as the first command inside Handsoff.emf was the best solution.
      >
      > Boy, this editor is very slick.
      >
    Your message has been successfully submitted and would be delivered to recipients shortly.