A language that compiles to Bash and Windows Batch
81–90 of 148 posts
Re: A language that compiles to Bash and Windows Batch
#82I must have done it wrong. In the late 80s, I created a Windows batch-to-executable compiler called Builder (extending the language greatly, to the point of menus as language constructs). Made a decent living off it, too!
Re: A language that compiles to Bash and Windows Batch
#83Re: A language that compiles to Bash and Windows Batch
#84How should I pronounce the name? I read “batsh” as a homophone for “batch” [bæʧ], which is unfortunate. Is it supposed to be pronounced as two syllables [bæɂ.ʃ] or something like that?
Re: A language that compiles to Bash and Windows Batch
#85I am the author of Batsh. Batsh is a toy language I developed 2.5 years ago in a hackathon. It was just for me to play with OCaml. Feel free to play with it at http://batsh.org/ .
Re: A language that compiles to Bash and Windows Batch
#86Earlier quoted context omitted.
Well sure, but these days PowerShell is what Windows people use for anything non-trivial.
PowerShell took everything that was great about .NET and combined it with everything that was terrible about Bash. So we have, yet again, a difficult to understand language for shell scripting.
Re: A language that compiles to Bash and Windows Batch
#87Earlier quoted context omitted.
The attraction for me is not about portability, it's about having a better language to write CMD script. Even when you know you have Python available sometimes you still need to glue things together with CMD.
> sometimes you still need to glue things together with CMD why? is there something cmd can do that python can't? one example is enough...
Re: A language that compiles to Bash and Windows Batch
#88Earlier quoted context omitted.
Windows has knock-off versions of several unix tools: grep = findstr cat = type which = where sort = sort more = more sudo = runas
Batsh already has some built-in functions which are, i assume, implemented on top of equivalent commands on either platform - for example, readdir() is implemented on top of either ls or dir. It seems plausible that more could be implemented on top of other pairs like these - for example, a searchfile() on top of grep and findstr, impersonate() on top of sudo and runas, etc. Perhaps what it really needs is an extensi…
Re: A language that compiles to Bash and Windows Batch
#89Earlier quoted context omitted.
> sometimes you still need to glue things together with CMD why? is there something cmd can do that python can't? one example is enough...
It's not about can or can't I think. Examples: Language runtime can't be installed, system locked down with deepfreeze, not enough permissions..
Re: A language that compiles to Bash and Windows Batch
#90[1] "Windows support is comming soon. " https://ocaml.org/docs/install.html