sponsor Vim development Vim logo Vim Book Ad

fcsh tools : you can compile .as and .mxml files from vim via fcsh : Flex Comipler SHell

 script karma  Rating 18/8, Downloaded by 1341  Comments, bugs, improvements  Vim wiki

created by
mike rowe
 
script type
utility
 
description
fcsh can compile actionscript 3 and mxml files.
included are fcshserv.sh and fcshcmp.sh.
fcshserv.sh should be launched manually before you edit
.as or .mxml files.
then, you can execute fcshcmp.sh from vim to compile and optionally run .swf file.
 
install details
requirements:
- fcsh ( http://labs.adobe.com/wiki/index.php/Flex_Compiler_Shell )
- bash

Tested only on GNU/Linux. Might work on *nix or cygwin.

1) tar xvjf fcshtools.tar.bz2

2) cd fcshtools

3) cp *.sh <wherever you want>
it's recommended to put  the files to $HOME/bin.

4) set FCSH_VIM_ROOT = $<wherever you want>
if you don't set this environment variable, it'll look at $HOME/bin.

5) edit ~/.vimrc
if you put the files to $HOME/bin, then add these:
    autocmd BufNewFile,BufRead *.mxml,*.as :nmap <C-B> :!bash ~/bin/fcshcmp.sh %:p
    autocmd BufNewFile,BufRead *.mxml,*.as :nmap <C-A> :!bash ~/bin/fcshcmp.sh %:p run

<C-B> will just compile the current file being edited.
<C-A> will compile and run the .swf on flashplayer.

6) bash $FCSH_VIM_ROOT/fcshserv.sh
this runs fcsh and creates a named pipe so fcshcmp.sh can send messages to.
Ctrl+C quits the server.

7) vim hello.as

8) <C-B> or <C-A>
 

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
fcshtools.tar.bz2 0.2 2007-02-15 6.0 mike rowe added more quotes.
fcshtools.tar.bz2 0.1 2007-02-04 6.0 mike rowe Initial upload
ip used for rating: 34.224.33.93

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
   
Vim at Github