NHacker Next
  • new
  • past
  • show
  • ask
  • show
  • jobs
  • submit
REBOL Shell Interface (rebol.com)
soapdog 1349 days ago [-]
REBOL was such a fun language to use. I wish it was open sourced earlier, then it might have made a larger impact. RED is a spiritual successor that deserves a look as well: https://www.red-lang.org/
rgrau 1349 days ago [-]
Both REBOL and Red feel magical to me. How is this simplicity achievable? Where is the trick?

I never could dig too deep into those, and couldn't find much info on the net. Is there a set of seminal papers/articles on the principles which those are based off?

I imagine there's Logo on one side of it, but I'm not sure about the bootstrap story, the toolchain, etc... Meta-II? Smalltalk, Lisp?

I recently found this book https://subscription.packtpub.com/book/application_developme... which I'd like to read if it talks about that holistic approach. Any comments? other pointers?

bryanrasmussen 1349 days ago [-]
the original design objectives. http://www.rebol.com/docs/design-objectives.html

I remember a long time ago an interview with the original language implementer where he talked about drawing inspiration from some things in Lisp but I can't remember enough to google forward to the document.

9214 1348 days ago [-]
Historically, Rebol family takes roots in the ideas of symbolic programming, denotational semantics and distributed computing. It never was an academical project (so you won't find any papers or articles), but rather a mix of pragmatism mixed with nonacceptance of the current state of software, so there's no magic to it: you reject the bloat and keep things simple.

The core idea is that, in Red/Rebol, you don't write "code" in the usual sense of the word, but rather load a data structure in memory that interpreters/compilers then process.

This data structure is a concrete-syntax tree (CST), a product of lexing syntactically-rich data format (think of a human-centered, futuristic JSON with unique literal forms for things like IP addresses with RGBA tuples, dates in various ISO formats, monetary values, URLs, e-mails, etc). The result of evaluation, then, is the end game of interpreters/compilers "walking" this CST — and each one can interpret the same tree differently.

So, Red/Rebol is both a programming language and a data format, there is no distinction between code and data. Rebol called itself "messaging language" because this CST, coupled with semantic rules for its interpretation, constitutes an embedded DSL (aka dialect), a message that you can exchange not only between machines (as a data structure), but between machines and humans (as a readable format).

Implementation-wise, the leverage comes from the runtime library that reuses what OS provides, high degree of polymorphism, everything being a first-class citizen, and above-mentioned syntactically-rich homoiconicity with general orientation towards linguistic abstraction.

With all of that we end up with a tool (speaking of Red) that covers the whole spectrum of software development, from metal to meta: user-land functions that seamlessly operate on CST values and enable meta-programming at run-time without macros, and a set of dialects that process said CST and encapsulate the problem domain's complexity, like e.g. VID for declarative GUI specification, Draw for raster drawing, Parse for creating other DSLs (think of it as Meta-II on speeds, wearing jet-rollers) and Red/System for low-level programming. All packed into a few megabytes.

These are the principles. Rebol was an interpreted language bootstrapped from C, Red is both compiled and interpreted: runtime is written in Red/System, and bootstrapping compiler with Red/System toolchain are written in Rebol2.

So, Red is written in itself, Red/System and Rebol; Red/System is a dialect of Red; Rebol is 90% compatible with Red (roughly the same data format and language semantics). Let this meta-circularity sink in.

Balbaert's book is IMO a very shallow explanation of the language basics, often plain wrong and technically incorrect, so I cannot in good faith recommend it, especially if you are a newcomer to Rebol family with ambitions to go advanced and master the tool.

WRT pointers toward design-centered discussions around Red/Rebol, consider to join community Gitter channel and read wiki articles. E.g. one of them (shameless plug) goes a bit more into conceptual underpinnings that I described above.

https://gitter.im/red/red

https://github.com/red/red/wiki/%5BDOC%5D-How-Red-works,-a-b...

rgrau 1348 days ago [-]
Wow, thanks so much for this answer.

I'm just going to add this link here to another explanation of yours I found around that expands on some of the unique aspects of Red: https://www.reddit.com/r/redlang/comments/aebxct/contrast_re... .

Thanks again

Apofis 1348 days ago [-]
While Red seems to be in active development, with over 10,000 commits, the community seems to be absent... odd.

https://github.com/search?o=desc&q=language%3Ared&s=stars&ty...

9214 1348 days ago [-]
A rather strange thing to say, given that (a) Github arbitrary limits number of displayed repositories (try to refresh the page a few times) (b) there is Gitlab and other Git-repository managers with VCSs (c) there's a Gitter chat with daily activity [1].

It's true that community is small (yet tightly knit), but I wouldn't go as far as to call it absent.

[1]: https://gitter.im/red/red

techdragon 1347 days ago [-]
TLDR: Red desperately needs its own community maintained learning materials.

It’s all about signalling.

I’ve meant to learn more about Red for years but keep putting it on the back burner because I can never seem to find a cohesive set of material to self-learn from. (I want a book. Like https://doc.rust-lang.org/book/ - doesn’t have to be great, but it’s my minimum bar for entry, one cohesive document to learn the language, syntax, grammar, keywords, whatever standard library exist, maybe even a tutorial or two along the way... Perl, TCL, Python, Rust, Ruby, Go, Prolog, all the good languages have a book like learning document with sections and chapters I can work through, usually they combine it with their standard library reference too.)

The Red community does look absent/dead/deeply in decline by the standard of other languages. Myself, and I’m sure many others, pass over and ignore it time and time again because without a more obvious set of signals that its worth our time, (I have extremely limited time for learning dead languages, they are not worthless, it’s a matter of priorities) we just move on to other things after we fail to see why it’s worth learning any more than “Red is a cool language descended from REBOL, but it seems kinda like no one uses it so it might not be worth the time to learn, because if it really was awesome surely it would be more popular and have books and stuff”

9214 1347 days ago [-]
Interesting point, thanks. We do have community maintained learning materials [1] (+ wiki itself), official docs [2] and formal specification [3]; granted, even if put together they don't match the quality of a cohesive user guide.

[1]: https://github.com/red/red/wiki/%5BLINKS%5D-Learning-resourc...

[2]: https://doc.red-lang.org/

[3]: https://github.com/meijeru/red.specs-public

techdragon 1347 days ago [-]
Thanks for the links, I gave them a look through and some of the most useful ones are buried under poorly named links in other places, when they really should be prominent links on the main website. The material is available and somewhat easier to find than the last time I looked into Red/REBOL but it’s definitely in need of improvement.

Especially https://static.red-lang.org/red-system-specs-light.html - It needs work but it’s a LOT closer to the kind of documentation I’m looking for when starting to learn a language. I found it looking at the third link which looks like an attempt to improve on of the other pages you linked to.

It clarifies much of the remaining confusion I had regarding comments I saw on the internet about how you can just use any REBOL docs to learn Red, by explaining the bootstrapping process, and it does so clearly in the first few paragraphs no less. It’s this kind of writing style where the complexity is gradually built up in layers of understanding is very valuable for some people while learning a new language.

But the under construction docs have some real shocking writing in them. The data types page is pretty bad. “Where most languages have 6-8 base datatypes, Red has almost 50. Many of these have unique, literal forms. “ then a few sentences later “To use Red effectively, you should become familiar with all the datatypes available.” This is definitely not the way to encourage a new user, imagine how a person who has only learned JavaScript or Python is going to feel about Red when they read that page. I would bet that many novice programmers leave that page with the impression that Red is nearly 10 times more complex than the languages they already know.

It’s worth considering the lessons learned by the Rust community while building their documentation. While not every programming language will have Steve Klabnik and Carol Nichols to write tremendous documentation... every programming language can learn at least a little bit from how they built it up the Rust docs and made keeping them up to date an important part of the community’s priorities.

9214 1347 days ago [-]
Thank you for taking your time to do a review! The prescriptive tone ("you should") on datatypes page doesn't really match the intent of the reference documentation (i.e. to inform), I agree.

Even if 50 vs 6-8 contrast sounds off-putting and overly sensationalist, it doesn't mean that language is more complex than its mainstream cousins. For example:

  ping @techdragon from http://www.rebol.com/docs/shell.html thread via hacker-news@techdragon.io
  today at 20:23:17 UTC
  say: your HN account was created on 11-February-2013 and has 1455 karma points 
Is a Red code (or rather data) containing 8 examples of unique datatypes (@reference, URL, e-mail, date and time, integer and flavors of symbols). One can even write a DSL that would understand it and send you a mail over SMTP or something.

I'd rather say "datatypes belong to 3-4 separate classes, each with a distinct yet simple semantics", and that "the set of their literal forms is diverse enough to count half a hundred exemplars; that makes the language simple, and the code written in it expressive". And then maybe build-up a motivation to study these classes ("to use Red effectively"), outline the studying path to take ("become familiar").

I don't follow Rust closely, is there any summary/takeaway of its history with documentation and community's lessons that I can read?

techdragon 1347 days ago [-]
That does sound like a better way to explain that there are many types. Definitely worth opening a PR and making that change to the data types doc page.

As for the history of the rust documentation. One of the best people to talk to would be Steve Klabnik https://steveklabnik.com so I would recommend reaching out to him.

9214 1347 days ago [-]
TBH, the whole datatypes section needs a revamp. Will put Steve's blog on my weekend reading list. Cheers!
chriswarbo 1348 days ago [-]
I followed the Red blog for a while, but it seemed to get derailed into cryptocurrency nonsense :(
tangus 1348 days ago [-]
Yeah, that was a silly year we'll never get back, but they seem to be on track again now.
9214 1348 days ago [-]
"Cryptocurrency nonsense" was an idea to create a local economy around Red as an open-source project, based on community-provided services and backed by an ERC-20 token.

Think of it as a solution to the class of problems of the current interest, such as financial compensation to FOSS maintainers, incentives for contributors, tipping high-quality learning material and insightful blog posts, etc.

This didn't pan out in the near-term though. Part of this blockchain move was also a nod toward Rebol's ideas concerned with distributed computing and decentralization (another hot topic): IOS and X-Internet, albeit with smart contracts instead of Reblets. [1]

[1]: http://www.rebol.com/ios/ios-intro.html

praptak 1349 days ago [-]
Is it open sourced? From looking at http://www.rebol.com/license.html it looks like merely free to use.
soapdog 1348 days ago [-]
REBOL 3 is FOSS. There is a fork that is actively maintained at https://github.com/zsx/r3
draegtun 1348 days ago [-]
The best branch to follow is https://github.com/metaeducation/ren-c

Additional references: http://rebol.info/ | https://github.com/r3n

tgv 1348 days ago [-]
Such a flashback. I even had Rebol on my resume back in 2002, under the "scripting languages". I'll be damned if I can remember how it works, though.
enduku 1348 days ago [-]
There was a REBOL clone named Sherman [0], written by Joe Marshall. He co-authored REBOL 1.0 and wrote Sherman after he left Rebol Technology. REBOL is such a powerful and simple language, it's a shame it wasn't open sourced earlier.

[0]https://web.archive.org/web/20000303130911/http://www.vsf.ca...

glofish 1348 days ago [-]
the fundamental problem with Rebol was cultural,

the creator had an ancient/dinosaur mentality where he thought selling the language itself was the business proposition, hence the licensing and limits that ultimately killed the language

pyuser583 1348 days ago [-]
This makes me really happy.

I've been watching REBOL/RED anticipation, and recently, frustration.

At first they looked amazing. Then it was clear they weren't being adapted. Now I'm just hoping other languages will be inspired by them.

9214 1348 days ago [-]
Rebol died as a siloed tech and a late-bloomer in the age of open-source, Red is chugging along, but the rub is that everyone appears to be watching and anticipating from afar, while very few of the followers help the project to achieve its goals and gain the adoption that the public seemingly wishes for.

I don't know if this is a historical/cultural problem with the language family itself, or if it's a matter of project's priorities and community incentives. What I do know is that lack of initiative won't bring your dreams to fruition.

elfgoh 1348 days ago [-]
Total newbie here: Are there any similarities between Elm and Rebol/Red?
9214 1348 days ago [-]
None or very few surface-level resemblances. Both projects live on the different planes of abstraction, have different goals, and take different paths in achieving them.
mucholove 1348 days ago [-]
2 questions:

A) is Rebol 2 open source? If no, why?

B) What are the big gotchas?

oofoe 1348 days ago [-]
REBOL 3 has been open sourced, at least to some extent: http://github.com/carls/R3A110

As usual with this kind of conversion there were things they couldn't open source or otherwise include.

The biggest problem (for me) with R3 is that they decided to redo REBOL 2's incredible compositing GUI environment, but ran out of runway before they could finish. It needed a rework -- people expect more from modern apps. But R2's GUI stuff is just so good, simple and orthoganal. It has completely spoiled me for any other GUI platform. I even wound up implementing a chunk of their GUI SDL in Python so I could bear to work with Wx.

However, it's still a pretty small language and has some really nice capabilities. It's very different from a lot of other languages, but it's also one of the faster ones to develop in. Using R2, I was able to provide and support rich GUI apps for a department at my company that I wouldn't otherwise have been able to help. These weren't typical line-of-business electronic forms either, but graphical editing tools with fullscreen interfaces, database connectivity and heavy parsing.

I really miss using REBOL...

unixhero 1348 days ago [-]
Is Rebol related to Red and REXX?
Jtsummers 1348 days ago [-]
Red was inspired by REBOL and based on it. Since Carl Sassenrath helped develop the Amiga, I would imagine ARexx could've influenced his design of REBOL.
9214 1348 days ago [-]
Red is a "reboot" of Rebol, yes.
Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact
Rendered at 23:15:56 GMT+0000 (Coordinated Universal Time) with Vercel.