From mboxrd@z Thu Jan 1 00:00:00 1970 MIME-Version: 1.0 Date: Thu, 30 Aug 2012 15:36:36 -0500 Message-ID: From: Jason Catena To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Content-Type: text/plain; charset=UTF-8 Subject: [9fans] make-shells that create a file for you Topicbox-Message-UUID: b53b3ae0-ead7-11e9-9d60-3106f5b1d025 >>> anyway, a meld of Rc shell and mk? crazy idea. >> Inferno (Vitanuova) released a "mash" a ways back, but apparently the sources were lost. It was mind-bogglingly interesting! > In case anyone's interested (like I was): > http://www.vitanuova.com/inferno/man/1/mash.html I kept expecting to see the make-shell act proactively to create a file, if the shell encountered a reference to a file that did not exist in the filesystem, but for which it had a matching creation rule. For example, presume someone wants to cat a formatted man page file, but only the .1 sources exist, and the make-shell knows how to create the file. When the make-shell sees that the user wants to reference a file that does not yet exist, it will go ahead and create the file (kind of like how the plumber does things, including creating new files, based on the patterns it gets). This completely hides the make step execution, but still allows the user to (re)define how files are made, and requires integration with the shell. On the other hand, mash, as I understand it, forces the user to type make and a file target. This to me is not different from the current way files are made with make tools, so I'm not sure what was gained by bundling it into the shell. Of course, the suggested feature does slow down the shell when it encounters a file that does not exist, since it has to scan through its rules for a possible creation rule, rather than just exit with an error. Jason Catena