2019-11-16 at 8:25 PM UTC
Sup guys. So i've been thinking for a while now, how awesome and convenient it would be to have a shell/terminal emulator compatible with all major platforms, complete with it's own shell scripting language, built-in tools and utilities and basically everything you'd expect a modern shell/terminal to have, it would come shipped with all it's dependencies maybe as a PE or with an installer for windows, but i'd prefer it to be fully self contained.
What i also want to do is write a simple IDE to be used with the shell scripting language. Now i know how to write the utilities i envision and i plan on writing the IDE and terminal part of the program in NodeJS and Electron. The issue is however that in order for this to work i will need to write an interpreter as well, which i really don't have any experience with obviously i need to write something that is able to read in the shell scripting language translate it to something that i can make system calls with and somehow have the interpreter understand logic operators as well.
With regards to programming i am the most proficient in Python, and yeah i know, making an interpreter with an interpreted language is about as inefficient as you can be. But i would at least like to make a prototype in this way.
I've been getting better at the .NET languages(.NET Core mainly since it is cross platform), so the final version of the interpreter might be in C# or F# but right now i don't think i could pull it off, that said, i really think this would be a cool project to work on and even if the finished product is a tad slow, it would still be great especially as a PE, where you just take your shell/term with you and no matter where you go or on what platform you are you got your favorite shell right there.
In any case i was wondering if you could tell me a little on how to go about the process of designing a shell scripting language and maybe point me in the right direction to get started on an interpreter for that language.
Thanks guys.
2019-11-17 at 1:08 AM UTC
I know you've talked about this before.
Wouldn't this all be dependent on the OS supporting the language? Maybe good for personal use but seems like reinventing the wheel.
2019-11-17 at 2:16 AM UTC
This post has been edited by a bot I made to preserve my privacy.
The following users say it would be alright if the author of this
post didn't die in a fire!
2019-11-17 at 4:10 AM UTC
Language design is one of those things I've been pretty interested in for a while but haven't ever found a compelling project to really use it for and god knows no one is going to pay me for it. I started a much longer reply but don't have time to finish it at the moment.
The basic pipeline for an interpreter is lex -> parse -> evaluation. Here's some high level stuff on each stage:
https://en.wikipedia.org/wiki/Lexical_analysishttps://en.wikipedia.org/wiki/LL_parserhttp://wiki.c2.com/?EvalApplyLL parsers aren't the only parsers but they're the most common ones that can be well implemented. And eval/apply is the only execution strategy for interpreted languages but it's one of the easier ones to understand and implement (although it is still kind of magical).
Hopefully will be back with more deets hopefully that's some reading to get started with, happy to answer more specific questions.
The following users say it would be alright if the author of this
post didn't die in a fire!
2019-11-17 at 5:26 AM UTC
My hair is real, thank you very much
2019-11-17 at 6:09 AM UTC
Originally posted by Lanny
My hair is real, thank you very much
you will look gorgeous with long hairs.
The following users say it would be alright if the author of this
post didn't die in a fire!
2019-11-17 at 1:10 PM UTC
Lanny looks like this guy who used to blow me for weed
2019-11-18 at 3:39 AM UTC
aldra
JIDF Controlled Opposition
Originally posted by Lanny
ENHANCE
The following users say it would be alright if the author of this
post didn't die in a fire!
2019-11-18 at 3:42 AM UTC
aldra
JIDF Controlled Opposition
no I think you've already excelled beyond what expertise it could provide you
The following users say it would be alright if the author of this
post didn't die in a fire!
2019-11-18 at 3:42 AM UTC
using a python, now that's an advanced technique in both programming and gay sex
The following users say it would be alright if the author of this
post didn't die in a fire!
2019-11-19 at 6:05 PM UTC
There's too much to support to capture everything. If you're looking into lexers and parsers, the canonical literature seems to always be the dragon book, but most people never read it. Start with a domain specific language and build from there. A good introduction:
https://www.youtube.com/watch?v=zJ9z6Ge-vXs
The following users say it would be alright if the author of this
post didn't die in a fire!
2019-11-23 at 2:23 PM UTC
Bump for myself. Good thread Sophie from the past you always have the greatest ideas. Let me delve into my digital library to see if i have "The Dragon Book" it's not my library it's more of a shared thing on a hidden service but that's beside the point. We should have a NiS book repository for excellence in computer science.
That said, didn't i send you like a gig of PDFs once Lonnie? Also lex -> parse, got it. Whether people usually read teh canonical resources or not is irrelevant, i learned to code with books, and the internet and a shitty text editor so that should be fine.
Also @Filtration, i appreciate the point you're making and i appreciate your input on .NET but Node and Electron are easy and the first iteration will not be "Production" as it were. Also, no OSS until i got something good. That said, while i will be reading the relevant literature i will also just be fucking around with Node and Python because i enjoy that, so you know.