10 votes

ctypes.sh: a Bash plugin that provides a foreign function interface directly in your shell

3 comments

  1. priw8
    Link
    There's a fun little section called "what people say" at the bottom of the README. I heavily relate to one of the comments there:

    There's a fun little section called "what people say" at the bottom of the README. I heavily relate to one of the comments there:

    "I never knew the c could stand for Cthulhu."

    5 votes
  2. zestier
    Link
    This one is actually pretty cool. I'm unsure I'd ever go through the effort to install it even if I came across a case that its a good fit, but I could definitely see using this if it was a native...

    This one is actually pretty cool. I'm unsure I'd ever go through the effort to install it even if I came across a case that its a good fit, but I could definitely see using this if it was a native feature of Bash. I can't think of any examples right off the top of my head, but I'm sure I've had cases in the past where being able to just call some little function without needing to build a whole wrapping process would've been useful.

    The example that uses malloc from Bash is absolutely disgusting though.

    3 votes