10 ms·
Parinfer – Simpler Lisp Editing
- sbjs 8y agoThis is really amazing and it's too bad the author is getting so little from his Patreon for making it! But at the same time I understand why. People can't contribute to every open source project that increases their productivity, there's just too many of them. But what other options do innovative geniuses like Shaun have to keep making things like this? Make a kickstarter for a product? Nobody would bite for small but invaluable utilities like Parinfer. Commercialize it and keep it closed source as an IntelliJ plugin? Would be incredibly hard to market. Keep it open source but charge for support? It's not complicated enough, he'd have to add a gazillion configuration options and intentionally bloat it just to justify it. I would really hate to see things like Parinfer die out because most people wouldn't justify spending the time making it, or would make it but wouldn't open source it.
- hashkb 8y agoI think its because so few people get paid to wrote Lisp.
- shawn 8y agoNah, open source just isn't lucrative. https://www.patreon.com/sindresorhus https://www.patreon.com/sindresorhus Most JS devs know sindresorhus by reputation. You can't help but knowing him through his work. He even put up a separate twitter solely because people kept wanting a way to see whenever he made a new github repo. Patreon makes him $3300/mo. So that appears to be the ceiling for all of us.
- amelius 8y ago> Nah, open source just isn't lucrative. And closed source isn't either when it comes to productivity tools (because there are so many free alternatives).
- woogley 8y ago> Patreon makes him $3300/mo. So that appears to be the ceiling for all of us. Hopefully it becomes an average, not a ceiling. We're not all going to make the next Vue, but that guy is getting $16k/mo https://www.patreon.com/evanyou https://www.patreon.com/evanyou .. that's what I consider the ceiling.
- burlesona 8y agoI think the open source model that has been shown to work is to make a great code product for free and then add a few more awesome features for a “pro” version with support attached. That’s how Sidekiq works and he’s making good money: https://www.indiehackers.com/interview/how-charging-money-for-pro-features-allowed-me-quit-my-job-6e71309457 https://www.indiehackers.com/interview/how-charging-money-fo...
- pmoriarty 8y ago"People can't contribute to every open source project that increases their productivity, there's just too many of them." I'm sure there are people on HN who can do just that, and much, much more. Some of them may even use parinfer. But whether they can and whether they want to contribute are two different things. For me the more interesting question is how the tiny minority of people who have gotten their hands on the overwhelming majority of money, power, and resources in this country and around the world can be persuaded to use what they have in socially constructive ways rather than for the benefit of the tiny, exclusive minority they are part of.
- sbjs 8y agoThis gives me an idea for a platform that: - looks at your Github repos - looks through all your dependencies - lists all the projects you depend on that support donations - shows you how much (or rather little!) they're making now - shows you the (Patreon) rewards you can get for supporting them - allows you to support them right there and then! I honestly think this is a legitimate idea and kind of want to pitch it to Y Combinator right now. It would be like something that ties Patreon and Github together. --- Okay I just posted this idea to Hacker News, find it in my submissions if you're interested :)
- lubonay 8y agoSounds like a cool idea for a free open-source project. Too bad your Patreon for it would be somewhat underfunded...
- sbjs 8y agoChicken v Egg! Haha, did not think of that :D Actually I think a Kickstarter would be more appropriate for this, but even then it seems unlikely to get any funding. I think going straight to a VC would be my best bet.
- bostonvaulter2 8y agoNah, just build it. A VC would cause the resulting service to end up very poor due to money pressure.
- coldtea 8y ago>This is really amazing and it's too bad the author is getting so little from his Patreon for making it! But at the same time I understand why. People can't contribute to every open source project that increases their productivity, there's just too many of them That's not a valid reason. They can also pick and contribute to their 3-4 more important, or to their 3-4 favorites, or to those that look more in need (eg. not much need do donate to Mozilla for example). But how many Lisp programmers are out there anyway, and use this? The intersection should be quite small, compared with most famous FOSS projects for languages like Java or Python (and even those projects don't get much).
- deleted 8y ago[deleted]
- qop 8y agoIt's not making much money because it's not that conducive to writing real lisp code with. Nobody thinks about sexprs the way parinfer does unless that's their first encounter with them. If you went and taught parinfer users how to use paredit, they'd wonder why paredit is so much easier and feels more w useful to them. Additionally, it's a niche market in the first place. People aren't exactly clambering for more lisp dev tools except in recessed corners of the academic universe and places where clojure is used. Aside from those users, there's little demand for a tool like this, and that market is like I said, further eroded by significantly higher quality tooling that's already available. Not every piece of code someone writes is worthy of being paid for. Not every piece of code written deserves to have been written in the first place, unfortunately.
- jamesrcole 8y agoI've sadly never gotten around to using Lisp, but even still, this kind of thing excites me. I think there's a lot of untapped promise in supporting structure within free-flowing text editing, like this does.
- hashkb 8y agoYou don't realize how terrible things like JS are until you experience the power and freedom.
- always_good 8y agoThat was the first phase. But ultimately Lisp taught me not to overvalue technical superiority, so I eventually stopped using it.
- cellularmitosis 8y agoI found this to be a great intro to the ideas of lisp. He covers macros, the Y Combinator, the meta-circular evaluator, and even a 62-line implementation of lisp in lisp. I’ve read about these ideas separately but had never seen them all together in one presentation, with examples. https://youtu.be/FRaNUsiD_BA https://youtu.be/FRaNUsiD_BA
- mackeprm 8y agoI'm using the atom parinfer plugin for my clojurescript projects and it makes development so much easier! The "it feels like writing python" analogy really fits. Now, if only there was a jump to function definition by ctrl+lmb for clj/atom it would be the perfect environment!
- simongray 8y agoAlso coming from Python and now using Parinfer for Clojure/ClojureScript, but I use the implementation in Cursive (intellij Clojure plugin). Love it. The only problem is working on a shared code base where people don't bother to indent code properly.
- chrisoakman 8y agoI'm glad you like Parinfer! The only problem is working on a shared code base where people don't bother to indent code properly. Parlinter was designed for this purpose. Maybe you could suggest it to your team? https://github.com/shaunlebron/parlinter https://github.com/shaunlebron/parlinter
- simongray 8y agoThanks, that's a great suggestion, although I think this I'm probably not going to get it through. This is a team of probably around 50 Clojure developers using different editors and AFAIK I'm the only one using parinfer.
- modernerd 8y agoI loved using Parinfer when I was writing ClojureScript, but it also made me question the value of Lisp syntax. If brackets can be inferred from indentation, doesn't this imply that they're extraneous — that indentation only would be sufficient to write many Lisp structures?
- ryanianian 8y agoThat’s the attitude of Python with curly braces. But with lisp the significance of indented structures is up to the implementation (`if` and `let` are the same “syntax” but are conventionally indented differently).
- pera 8y agoYou should check Wisp: https://bitbucket.org/ArneBab/wisp/src/default/ https://bitbucket.org/ArneBab/wisp/src/default/
- lispm 8y agoOne can do that, but most Lisp programmers value the direct "source code is data" nature of Lisp - using s-expressions. Alternative notations were originally planned for Lisp when it was designed - some books were published using it, but for actual programming it wasn't used too much - especially since most implementations actually a) didn't support it or b) had s-expressions as a default/internally. Then several attempts to modernize Lisp with a different syntax mostly failed to get traction or failed big (like the Lisp 2 effort). Then some efforts failed to provide more than one syntax and also failed to appeal to people (Dylan). What we saw is a bunch of languages derived from Lisp with different syntax (ML, Logo, ...) and a bunch of Lisps for mathematics with different syntax (Reduce, Macsyma, ...). But the core Lisp programmers were never willing to give up the s-expression-based syntax. It has some clear advantages when manipulating code, especially in interactive programming.
- modernerd 8y agoThanks for these comments. I didn't realise alternative notations were planned and never took off. (Dylan in particular looks really interesting.) I can see the value of homoiconicity / code as data from the perspective of someone writing a parser. I've asked what writing code as s-expressions gets you as the end-user of a language before. People usually say, “macros” or “it's easier to manipulate code”. But macros exist in non-homoiconic languages, like Nim and Elixir. And in my short time using ClojureScript I'm not sure what manipulations Lisp syntax gave me that I don't already have with other languages in a modern text editor. I'd love to see examples of accomplished Lisp users on YouTube or elsewhere, to see what those code manipulations look like.
- nojvek 8y agoWhen I think about LISP and parens it just feels redundant if you’re gonna use indentation anyway. Parens are only useful if everything is on a single line. With new lines and indentation, things can become a lot cleaner like python style. I strongly believe python got so popular because of its very simple to read, almost pseudo-code like syntax that anyone could learn. List had great ideas, everything is a list, but dealing with parens hell makes me think it could be a lot more elegant.
- nabla9 8y ago>More than anything else, I think it is the ability of Lisp programs to manipulate Lisp expressions that sets Lisp apart. And so no one who has not written a lot of macros is really in a position to compare Lisp to other languages. When I hear people complain about Lisp's parentheses, it sounds to my ears like someone saying: "I tried one of those bananas, which you say are so delicious. The white part was ok, but the yellow part was very tough and tasted awful." – Paul Graham Lisp programmers don't deal with "parens hell". That's one of the misconceptions that come from outsider looking in. Parens are for the editor. Lisp indeed uses indentation and not parens as you said. It's very python-like that way."You have reached Lisp enlightenment when parens disappear" I think it would be real helpful to have editor for beginners that shows parents as transparent and low contrast, separately from the rest of the code. It would help people to understand they should not be trying to match them visually.
- egypturnash 8y agoIf Lisp uses indentation and not parenthesis, then why is my mental caricature of Lisp just ((())))(()))((())))()()()(())))((())))?
- dang 8y agoDiscussed in 2015: https://news.ycombinator.com/item?id=10547772 https://news.ycombinator.com/item?id=10547772
- agumonkey 8y agowho else tried but got back to paredit because of too many years of habits ?
- noctuid 8y agoI've argued that parinfer complicates lisp editing. Some notes critiquing parinfer: https://github.com/noctuid/parinfer-notes https://github.com/noctuid/parinfer-notes
- yogthos 8y agoPersonally, I prefer using paredit because it feels more predictable since you're telling it what to do explicitly. That said, I've heard from a lot of beginners that parinfer helped them get started with Clojure. Even if it's not optimal, I think there's a lot of value in the fact that it's easy to get started with.
- noctuid 8y agoI've never been a fan of paredit, but paredit, smartparens, and lispy are all far more powerful and (for me as well) more intuitive. I agree that parinfer deserves credit for being widely available for different text editors and for being fairly easy to pick up. I do think that the method is unnecessarily complicated though. When "paren mode" was still necessary, I think it was a much poorer choice for a newcomer than it is now.
- dragandj 8y agoThat's why few people are using things like parinfer. This demo might look cool to non-lisp programmers, but in lisp-land, everyone is using semantic editing (in Emacs or otherwise), and not line-based editing.
- noctuid 8y agoParinfer seems popular in the clojure community (even among those who have been writing it for a while) and among people new to lisp. In its favor, parinfer's listed selling point is simplicity and not power. I don't think it does simplicitly perfectly, but I think it does it better than paredit, for example.
- bpicolo 8y ago
- EricRiese 8y agoThe lego analogy is something I've thought about before. Inspired by Firefox's Tilt 3D[1], I've wondered if it makes sense to code in VR with indentation, or even level of the AST projected onto the z-axis. Wobbling the perspective around would probably be annoying and unnecessary, but hopefully a fixed angle, or one varying slightly with zoom could work. [1] https://addons.mozilla.org/en-US/firefox/addon/tilt/ https://addons.mozilla.org/en-US/firefox/addon/tilt/
- chrisoakman 8y agoI did a quick project around this idea a while ago: http://oakmac.com/lisp-3d-1.gif http://oakmac.com/lisp-3d-1.gif http://oakmac.com/lisp-3d-2.gif http://oakmac.com/lisp-3d-2.gif
- dustingetz 8y agoIs there a place with a one slide, single demo, "type this, observe this, now type this, so you understand ZZZ"?
- dustingetz 8y agoI badly need something like this in http://www.hyperfiddle.net/ http://www.hyperfiddle.net/ - is this a bug in smart mode or am i doing it wrong ... ? edit: better video https://i.imgur.com/4BsYQ3e.gif https://i.imgur.com/4BsYQ3e.gif Exposing newbie end users to modal editing would seem to be a non-starter, i think smart mode needs to work
- dustingetz 8y agoupdate: I hacked up parinfer-codemirror to be modal and indicate mode visually, here is the result: https://i.imgur.com/xPDc4Wy.gif https://i.imgur.com/xPDc4Wy.gif I'm wondering if paren mode might be what newbies actually want, and they can go and learn about indent mode later?