or, if your app settings on Windows are working right, just

  os.system(r"start C:\path_to_outline\test.leo")

This way, the starting console closes immediately.  True, you have to edit 
the @command ...@key contents if you want to open some other outline 
(workbook.leo might be a good place for this command), but then you don't 
have to find and edit the helper file t.cmd.  

On Monday, March 12, 2018 at 10:54:41 AM UTC-4, Edward K. Ream wrote:
> ‚ÄčOn Windows I use the following @command node to open a test file. Change 
> it to @button if you like:
> @command F5-open-test @key=F5
> @language python
> import os
> c.saveAll()
> os.system("start  cmd /c t")
>     # Open ~/test.leo in a separate console.
>     # t.bat ends with exit so the console closes when I close Leo.
> leo_dir = g.os_path_finalize_join(g.app.loadDir, '..', '..')
> os.chdir(leo_dir)
> # print(g.os_path_abspath(os.curdir))
> Imo this is even better than closing and opening your dev .leo file.
> F5 saves any work in your dev .leo file and opens the *small* test file 
> in a console.  The console closes automatically when you close the test 
> file.

You received this message because you are subscribed to the Google Groups 
"leo-editor" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to leo-editor+unsubscr...@googlegroups.com.
To post to this group, send email to leo-editor@googlegroups.com.
Visit this group at https://groups.google.com/group/leo-editor.
For more options, visit https://groups.google.com/d/optout.

Reply via email to