3 ms·
Chris discusses the rationale in his blog post at https://chrisdone.com/posts/hell/ https://chrisdone.com/posts/hell/
by tmoertel 2y ago
Chris discusses the rationale in his blog post at https://chrisdone.com/posts/hell/ https://chrisdone.com/posts/hell/
- chongli 2y agoThanks for this! I read that but I'm still not convinced. Quote: They lean far too heavily on sub processes to do basic things. I thought this was the whole point of a unix scripting language! Most of the scripts I'm writing are not interactive REPLs or string-parsers, they're glue code for batch-invoking commands on files. Stuff like converting a bunch of FLAC files into MP3 with lame or avi video files into mkv with ffmpeg. What bash offers me is very terse command invocation and powerful filename globbing, including regexp substitution. Scripts like this are generally not intended to be used more than once or twice, and so a type system like Haskell provides is irrelevant here. If you're writing something that's going to be iterated on and maintained for years then you're writing an application, not a script.
- thesz 2y agoLet me introduce to you Kaldi, a speech-to-text engine. I put the link right into models directory, to save you some time. https://github.com/kaldi-asr/kaldi/tree/master/egs https://github.com/kaldi-asr/kaldi/tree/master/egs There are a bunch of shell, Perl and Python scripts there, with some awk in between. These scripts are often copied almost verbatim between models and this, believe me, can lead to all sorts of errors. The running joke around working with these scripts was "all these .sh should be .hs," i.e., these scripts should be implemented in Haskell.
- 082349872349872 2y ago> generally not intended to be used more than once or twice on that note: https://news.ycombinator.com/item?id=41489436 https://news.ycombinator.com/item?id=41489436