Richard Bucker

tools for the installinator

Posted at — Mar 6, 2015

I’ve found the first two extensions to the installinator/macroinator. lisp and tcl. One of the interesting things I noticed was that both languages, especially tcl, might work well on the command line for a REPL. For example in tcl$ tclrepl fcopy “file1.txt” “file2.txt”and then in lisp$ lisprepl (fcopy “file1.txt” “file2.txt”)Inside the REPL I’m pretty certain all I need to do is join the args back together. The quoted params are already handled by the basic command line stuff.  It’s also interesting to note that a space is the separator character in both languages.executeMe := strings.Join(flag.Args()," “) and then send the execMe to the interpreter. I have not decided on the exact command line but it should be pretty simple. There are only a few things that the REPL actually needs.optional configuration file (-c)optional file to execute (-f) And the remaining args are what will be executed after the file(s) have been loaded.First load and execute the configuration file. The config file might import or include other files of a similar type. They will all be executed as they would in their native language. Anything at layer 0 will be considered a global.Next the executable (f) file will be loaded and executed. Once this file returns to the main() then the command line is checked for a possible command to execute.Internally, when the macros are individually initialized they should be adding to the language reference instance and connecting to the installinator macros. The initial work will be started by wrapping the macroinator with some libraries. This way I can POC before migrating the remaining installinator functions.