TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Morbig – A Static Parser for Posix Shell

49 pointsby rasmusfabbeabout 3 years ago

4 comments

pabs3about 3 years ago
Some talks related to this from the Debian conference:<p><a href="https:&#x2F;&#x2F;debconf16.debconf.org&#x2F;talks&#x2F;63&#x2F;" rel="nofollow">https:&#x2F;&#x2F;debconf16.debconf.org&#x2F;talks&#x2F;63&#x2F;</a> <a href="https:&#x2F;&#x2F;debconf18.debconf.org&#x2F;talks&#x2F;90-mining-debian-maintainer-scripts&#x2F;" rel="nofollow">https:&#x2F;&#x2F;debconf18.debconf.org&#x2F;talks&#x2F;90-mining-debian-maintai...</a> <a href="https:&#x2F;&#x2F;debconf19.debconf.org&#x2F;talks&#x2F;105-symbolic-execution-of-maintainer-scripts&#x2F;" rel="nofollow">https:&#x2F;&#x2F;debconf19.debconf.org&#x2F;talks&#x2F;105-symbolic-execution-o...</a>
loxiasabout 3 years ago
Heck yeah! Thanks for this!<p>On a whim, I&#x27;ve been doodling ideas for a POSIX(ish)-shell compiled language. Seeing other people interested in such (probably useless, but fun) ideas encourages me.<p>Thanks OP! (I kinda wish that, of the 6 dependencies, I had heard of at least 2 of them, but beggars can&#x27;t be choosers. You do you!! And though I&#x27;ve never done so myself, People I Respect (tm) say that Haskell&#x2F;ML&#x2F;OCaml are respectable tools for building parsers anyway)
评论 #30840379 未加载
unhammerabout 3 years ago
That&#x27;s great =D Would be interesting to see a comparison to the parse that shellcheck gives[0][1], is this stricter and&#x2F;or more abstracted perhaps?<p>[0] <a href="https:&#x2F;&#x2F;github.com&#x2F;koalaman&#x2F;shellcheck&#x2F;blob&#x2F;master&#x2F;src&#x2F;ShellCheck&#x2F;Parser.hs" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;koalaman&#x2F;shellcheck&#x2F;blob&#x2F;master&#x2F;src&#x2F;Shell...</a><p>[1] <a href="https:&#x2F;&#x2F;github.com&#x2F;koalaman&#x2F;shellcheck&#x2F;blob&#x2F;master&#x2F;src&#x2F;ShellCheck&#x2F;AST.hs" rel="nofollow">https:&#x2F;&#x2F;github.com&#x2F;koalaman&#x2F;shellcheck&#x2F;blob&#x2F;master&#x2F;src&#x2F;Shell...</a>
amir734jjabout 3 years ago
+1 for the clear and well documented parser. It takes serious dedication to write a hand-written parser and not simply use a parser generator.