   Is there a way I can do a macro in Unix?
  Is there a shorter way I can type in the following into Unix:>flex mytest.flx>gcc lex.yy.c -lfl -o mytest.scnIt would really speed things up for me if I could use macros. 
  Why not just use a makefile? ;  You could make a shell script that takes arguments, or you can make an alias. How you would do either depends almost entirely on which version specific OS and distro you are using. ;  what is a makefile? ;  make is a program used to automate compilations. You use a makefile to specify dependencies and compilation commands. In your case you use flex to create lex.yy.c from mytest.flx and you use gcc to create mytest.scn from lex.yy.c. So your makefile might look like:lex.yy.c: mytest.flx   flex mytest.flxmytest.scn: lex.yy.c   gcc lex.yy.c -lfl -o mytest.scn  Then you just type make at the command prompt, it will automatically perform compilation on the parts of your program that need to be updated.You can man make for more details. 