[{"data":1,"prerenderedAt":268},["ShallowReactive",2],{"project-20599230":3},{"id":4,"name":5,"line":6,"line_source":7,"title":8,"url":9,"domain":10,"maker":11,"posted_at":12,"year":13,"points":14,"comments":15,"rank_in_year":16,"shown_in_year":17,"top":18,"tier":19,"category":20,"subcategory":21,"format":22,"keywords":23,"reception":28,"sentiment":29,"stance_mix":30,"scored_comments":35,"aspects":36,"strip":40,"post_text":43,"what":44,"said":88,"maker_in_thread":184,"shape":191,"grid":195,"attempts":230,"same_week":231,"maker_shows":34,"maker_hidden":260,"reader_version":261,"card":262},"20599230","Purely Functional Scripting","Hi all, TopShell is a reactive scripting environment that I've been working on for a while.","maker","Show HN: Purely Functional Scripting","https:\u002F\u002Fgithub.com\u002Ftopshell-language\u002Ftopshell","github.com","continuational",1564819753,2019,131,19,348,2195,16,"notable","dev_tools","scripting environment","web_app",[24,25,26,27],"functional scripting","shell scripting","purely functional language","reactive notebook","curious",0.053,{"positive":31,"neutral":32,"mixed":33,"critical":34},2,6,0,1,9,{"idea":37,"docs":38,"design":39},{"positive":34,"critical":34},{"positive":34,"critical":33},{"positive":33,"critical":33},[33,41,33,33,42,41,33,42,33,41,33,41,33,34,33,41,33,41,33],3,5,null,{"problem":45,"audience":55,"pricing":43,"motivation":61,"time_to_build":68,"stack":74,"openness":85,"stage":86,"team_size":87},{"value":46,"source":7,"evidence":47},"Ad-hoc scripting over files, servers, HTTP and command-line tools is clumsy in existing languages and shells",[48,52],{"id":49,"by":50,"text":51},"20603960","maddyboo","TopShell looks very interesting, thank you for sharing! This is a problem domain which I've been thinking a lot about recently. I write tons of shell (bash) scripts. I hate bash…",{"id":53,"by":11,"text":54},"20604837","The primary use case I'm focusing on is ad-hoc scripting: When you have a task that involves some files, some servers, some HTTP requests, some command line tools, some data…",{"value":56,"source":57,"evidence":58},"Developers who write quick one-off scripts that may grow into larger software","inferred",[59,60],{"id":49,"by":50,"text":51},{"id":53,"by":11,"text":54},{"value":62,"source":7,"evidence":63},"Maker wanted a better way to do ad-hoc scripting and uses it for own scripting needs",[64,65],{"id":53,"by":11,"text":54},{"id":66,"by":11,"text":67},"20605077","Thank you for the long and thoughtful comment. I think you bring up a lot of valid points, and I don't have complete answers to all of them yet, but I'll do my best to address…",{"value":69,"source":7,"evidence":70},"a little over a year",[71],{"id":72,"by":11,"text":73},"20604879","I've been working on it for a little over a year. The biggest challenge so far has been designing and implementing a type system with the flexibility required for ad-hoc…",[75,81],{"value":76,"source":7,"evidence":77},"Scala",[78],{"id":79,"by":11,"text":80},"20652459","The reason is that I do Scala at my day job, and thus I'm simply more experienced in that than Haskell. While I've written a compiler in Haskell in the past, and prefer the…",{"value":82,"source":57,"evidence":83},"JavaScript (compiles to JS for the front end)",[84],{"id":79,"by":11,"text":80},"unknown","beta","solo",{"praise":89,"objections":108,"requests":121,"questions":134,"alternatives":164},[90,95,102],{"value":91,"source":92,"evidence":93},"Clear code examples in the readme","commenter",[94],{"id":49,"by":50,"text":51},{"value":96,"source":92,"evidence":97},"Playground is a useful way to try the language",[98],{"id":99,"by":100,"text":101},"20603490","yoz","This looks great, and I'm eager for more! I was initially put off by going straight to the repo's declared homepage (the Playground) and just seeing two empty text areas. The…",{"value":103,"source":92,"evidence":104},"Stream to stdin\u002Fstdout design idea would be useful",[105],{"id":106,"by":50,"text":107},"20605426","> TopShell can use such programs, but TopShell scripts can't currently become such programs. I'm still looking for the right way to do this - one way would be to have a `main :…",[109,113,117],{"value":110,"source":7,"evidence":111},"Bus factor of 1; project future uncertain",[112],{"id":66,"by":11,"text":67},{"value":114,"source":92,"evidence":115},"Cannot yet use own editor; web interface only",[116],{"id":49,"by":50,"text":51},{"value":118,"source":7,"evidence":119},"Scripts cannot yet be run as standalone Unix-style programs",[120],{"id":66,"by":11,"text":67},[122,126,130],{"value":123,"source":92,"evidence":124},"Pre-fill the Playground with an example",[125],{"id":99,"by":100,"text":101},{"value":127,"source":92,"evidence":128},"Document use with own editor or environment",[129],{"id":49,"by":50,"text":51},{"value":131,"source":92,"evidence":132},"Condense philosophy from wiki into the README",[133],{"id":49,"by":50,"text":51},[135,143,150,157],{"value":136,"source":92,"evidence":137},"How does it fit the Unix philosophy and piping?",[138,139],{"id":49,"by":50,"text":51},{"id":140,"by":141,"text":142},"20604650","iamwil","to OP: How long have you been working on it? What was the biggest challenge you ran into when working on it? How does piping work? Can you split and join the streams?",{"value":144,"source":92,"evidence":145},"Why Scala instead of Haskell or PureScript?",[146],{"id":147,"by":148,"text":149},"20645476","spleeder","Seeing how closely TopShell resembles Haskell I am curious why you chose to implement it in Scala rather than Haskell or Purescript.",{"value":151,"source":92,"evidence":152},"How are network requests pure?",[153],{"id":154,"by":155,"text":156},"20605312","gitgud","The first example is a HTTP request, aren't network requests inherently unpure? as they rely on state outside of the program and could cause side effects...",{"value":158,"source":92,"evidence":159},"Why magic imports in a purely functional language?",[160],{"id":161,"by":162,"text":163},"20600482","lidHanteyk","Looks like Elm. Why did you add magic imports? It seems strange to go for purely functional behavior and then add magic side effects.",[165,169,176,180],{"value":166,"source":92,"evidence":167},"bash\u002Fzsh",[168],{"id":49,"by":50,"text":51},{"value":170,"source":92,"evidence":171},"Groovy",[172],{"id":173,"by":174,"text":175},"20604377","zmmmmm","> I've tried to use many other languages to fill the gap of writing scripts that start as quick one-offs but have the potential to evolve into a more refined piece of software…",{"value":177,"source":92,"evidence":178},"Elm",[179],{"id":161,"by":162,"text":163},{"value":181,"source":92,"evidence":182},"Haskell and PureScript",[183],{"id":147,"by":148,"text":149},{"comments":35,"answered":32,"key":185},[186,189,190],{"id":187,"text":188},"20599250","Hi all, TopShell is a reactive scripting environment that I've been working on for a while. It's purely functional with type inference that runs as you type, as well as a bit of…",{"id":66,"text":67},{"id":53,"text":54},{"commenters":35,"max_depth":192,"maker_replies":35,"first_comment_mins":193,"lifespan_hours":194},4,7,145,[196,198,200,202,203,204,207,208,210,212,213,215,217,218,220,222,223,225,228],[187,33,33,197,11,34],"project\u002Fpositive\u002Fidea",[49,33,41,199,50,33],"project\u002Fneutral\u002Fidea",[173,33,33,201,174,33],"commenter\u002Fneutral\u002Fnone",[66,33,33,199,11,34],[106,33,42,197,50,33],[205,33,41,199,206,33],"20604426","dmix",[53,33,33,199,11,34],[99,34,42,209,100,33],"project\u002Fpositive\u002Fdocs",[211,34,33,209,11,34],"20604808",[161,31,41,199,162,33],[214,31,33,199,11,34],"20600762",[147,41,41,216,148,33],"project\u002Fneutral\u002Fnone",[79,41,33,216,11,34],[154,192,34,219,155,33],"project\u002Fcritical\u002Fidea",[221,192,33,199,11,34],"20605403",[140,42,41,216,141,33],[72,42,33,224,11,34],"project\u002Fneutral\u002Fexecution",[226,42,41,227,141,33],"20607927","project\u002Fneutral\u002Fdesign",[229,42,33,227,11,34],"20608233",[],[232,237,242,247,252,256],{"id":233,"name":234,"points":235,"category":236},"20624140","Zecoda",397,"ai",{"id":238,"name":239,"points":240,"category":241},"20634409","Data Structures and Algorithms in JavaScript",369,"learning_science",{"id":243,"name":244,"points":245,"category":246},"20634715","Glimpse",232,"data",{"id":248,"name":249,"points":250,"category":251},"20624371","Maesure",132,"productivity",{"id":253,"name":254,"points":255,"category":251},"20581915","Detoxify",117,{"id":257,"name":258,"points":259,"category":241},"20599756","Beatboxing for Kids",102,false,"v2",{"id":263,"name":5,"line":6,"ai":260,"cat":20,"year":13,"points":14,"comments":15,"rec":28,"s":264,"top":18,"kw":265,"maker":11,"domain":10,"tier":19,"attempts":33,"strip":266,"url":9,"mix":267,"praise":91,"objection":110,"sub":21},20599230,0.05,[24,25,26,27],"0300530503030103030",[31,32,33,34],1793990992279]