News for hackers. Stuff that matters.
Re:Osm.el – OpenStreetMap Viewer for Emacs by nanna on Tuesday March 15, 2022 @06:10AM (#30683519)
As someone who presents lectures using org-tree-slides [0] instead of Powerpoint, I can totally imagine this being useful for me.

I'm flabbergasted at how snappy and intuitive it is!

[0] https://github.com/takaxp/org-tree-slide

Re:Osm.el – OpenStreetMap Viewer for Emacs by taeric on Tuesday March 15, 2022 @10:39AM (#30685899)
I was also blown away by how much more responsive it is than the browser maps.
Re:Osm.el – OpenStreetMap Viewer for Emacs by akagusu on Tuesday March 15, 2022 @07:34AM (#30684095)
Thanks for the link, very useful.
Re:Osm.el – OpenStreetMap Viewer for Emacs by Hitton on Tuesday March 15, 2022 @06:28AM (#30683645)
I'm once again reminded of: "Emacs is a great operating system, only lacking a decent editor."
Re:Osm.el – OpenStreetMap Viewer for Emacs by nathell on Tuesday March 15, 2022 @06:48AM (#30683790)
That’s the adage oft repeated by people who had had a cursory look at Emacs, but haven’t been really using it. In reality, the opposite is true. Emacs is a great editor, but the operating system that it is [0] is lacking in many ways:

- performance is not great (although it’s getting better with the advent of native compilation in Emacs 28)

- the system language is awkward (no namespaces, dynamic scoping by default, ...)

- no preemptive multithreading

- etc.

On the plus side, it is auto-documenting and extremely malleable.

[0]: Yeah, it can be a full-fledged OS. Just add a Linux kernel: http://informatimago.free.fr/i/linux/emacs-on-user-mode-linu...

Re:Osm.el – OpenStreetMap Viewer for Emacs by zeveb on Tuesday March 15, 2022 @09:46AM (#30685183)
> the system language is awkward (no namespaces, dynamic scoping by default, ...)

RMS's dislike of Common Lisp really caused a colossal amount of damage. Imagine an Emacs written in Common Lisp instead of Emacs Lisp, with decades and decades of improvements. Having written a reasonable amount of software in both, Common Lisp Emacs would be very, very preferable, in part for the reasons you list and in part for others (e.g. a full-fledged, built in object system and improved extensibility).

Re:Osm.el – OpenStreetMap Viewer for Emacs by deng on Tuesday March 15, 2022 @01:22PM (#30688106)
> RMS's dislike of Common Lisp really caused a colossal amount of damage. Imagine an Emacs written in Common Lisp instead of Emacs Lisp, with decades and decades of improvements.

If Emacs were written in Common Lisp, only people on big mainframes would have been able to use it in 1985, and it probably wouldn't have become popular in the first place. Also, implementing Common Lisp would have taken much longer. RMS has said that his main goal with his LISP dialect was to keep the programming language as small and performant as possible, since at that time, machines had maybe 1MB of RAM (if you were lucky) and no virtual memory. This is why for instance he decided against lexical scoping (and still, Emacs was known back then as "eight megabytes and constantly swapping").

Re:Osm.el – OpenStreetMap Viewer for Emacs by lispm on Tuesday March 15, 2022 @04:56PM (#30691585)
IIRC, Coral Common Lisp ran on a Mac Plus, which had 1 MB RAM. It included an editor.
Re:Osm.el – OpenStreetMap Viewer for Emacs by schemingguild on Tuesday March 15, 2022 @02:41PM (#30689217)
I'm very interested in guile-emacs, not because I think it'll replace main emacs, but I do think it'd be really neat to have my config in a 'cleaner' lisp like scheme, a clojure like language, lokke[0], or even python[1]

[0]: https://github.com/lokke-org/lokke [1]: https://gitlab.com/python-on-guile/python-on-guile

Re:Osm.el – OpenStreetMap Viewer for Emacs by sreevisakh on Tuesday March 15, 2022 @10:23AM (#30685672)
That may be what nyxt browser is trying to do. The author claims that nyxt could be extended to be anything, including an alternative for emacs.

[1] https://nyxt.atlas.engineer/article/why-building-nyxt-instea...

Re:Osm.el – OpenStreetMap Viewer for Emacs by wrs on Tuesday March 15, 2022 @11:45AM (#30686756)
There has been some work on that over the decades (but of course not enough momentum): https://phemlock.common-lisp.dev/
Re:Osm.el – OpenStreetMap Viewer for Emacs by donio on Tuesday March 15, 2022 @04:49PM (#30691493)
> dynamic scoping by default

This is not much of a problem in practice these days. As you probably know it's trivial to enable lexical-binding for an entire source file and many (most?) modern packages do just that. It's even on by default in the scratch buffer. Emacs is just more user friendly than most other systems when when it comes to backwards compatibility.

Re:Osm.el – OpenStreetMap Viewer for Emacs by bananamerica on Tuesday March 15, 2022 @09:26AM (#30684939)
I'm pretty sure when the adage was created it was much closer to the truth. Now it's mostly a joke.
Re:Osm.el – OpenStreetMap Viewer for Emacs by throwawayboise on Tuesday March 15, 2022 @10:55AM (#30686107)
I started using emacs close to 30 years ago. As a text editor, it's pretty much the same as it ever was (the same goes for vi also).
Re:Osm.el – OpenStreetMap Viewer for Emacs by kqr on Tuesday March 15, 2022 @02:28PM (#30689033)
It's not, though, because you now have a wealth of choices beyond the text editor that comes bundled with Emacs.
Re:Osm.el – OpenStreetMap Viewer for Emacs by bananamerica on Tuesday March 15, 2022 @07:49PM (#30693482)
I mostly meant that what we expect from an OS changed a lot since then.
Re:Osm.el – OpenStreetMap Viewer for Emacs by kqr on Tuesday March 15, 2022 @07:53AM (#30684221)
It does have a decent editor, though: Evil mode.
Re:Osm.el – OpenStreetMap Viewer for Emacs by RobertMiller on Tuesday March 15, 2022 @09:35AM (#30685037)
Better than decent. I switched from neovim to evil mode a few years ago and never looked back.
Re:Osm.el – OpenStreetMap Viewer for Emacs by lycopodiopsida on Tuesday March 15, 2022 @10:02AM (#30685389)
I am in process of switching from emacs to neovim atm (doom evil user before). Whatever I do in emacs (emacs28, jit-compilation, M1) I still experience some UI lags l cannot get with profiler. I suspect slow lsp interface and suboptimal caching/gc. At some point I've tried neovim and was just surprised by how fast it feels.
Re:Osm.el – OpenStreetMap Viewer for Emacs by RobertMiller on Tuesday March 15, 2022 @10:14AM (#30685555)
Company mode is the big offender for me, it handles very large completion lists poorly. I'm not yet fully satisfied with the latency situation in my emacs config, but for me there is no going back. Evil mode let me keep almost all of the muscle memory I ever learned in vim/neovim, and the rest of the emacs ecosystem more than makes up for the latency issues in my opinion.
Re:Osm.el – OpenStreetMap Viewer for Emacs by amitp on Tuesday March 15, 2022 @10:51AM (#30686052)
Corfu might be worth a look, as a lighter weight alternative to company mode: https://kristofferbalintona.me/posts/corfu-kind-icon-and-cor...
Re:Osm.el – OpenStreetMap Viewer for Emacs by omaranto on Tuesday March 15, 2022 @02:54PM (#30689414)
And Corfu was written by the same person as this OpenStreetMap Viewer.
Re:Osm.el – OpenStreetMap Viewer for Emacs by lycopodiopsida on Tuesday March 15, 2022 @11:09AM (#30686269)
I've also experienced some heavy lag immediately after startup - maybe warming up the caches? Had a feeling it gets worse after each package update with compilation.

Long line performance is still a huge problem. Emacs team does an amazing job keeping up, but the age shows itself everywhere. In the end I've realized that org/magit were not life-changing for me, evil-mode it the only thing I care about. :)

Re:Osm.el – OpenStreetMap Viewer for Emacs by codemac on Tuesday March 15, 2022 @02:17PM (#30688888)
Honestly this is a big thing that emacs folks don't value, multi threaded performance.

I don't even use LSP because I have my own ways of browsing source code through emacs. So I go off and tout emacs' amazingness, but then when someone tries it and attempts to use what worked in other editors, it's a slow laggy mess.

Re:Osm.el – OpenStreetMap Viewer for Emacs by jfb on Tuesday March 15, 2022 @12:52PM (#30687649)
Emacs is a reflection or a rhyme of a great operating system; it has the critical feature of total inspectability/hackability, but the implementation is poor. There is no other system in use today that has that kind of total transparency all the way to the bottom, or at least, as far down as Emacs does.

I don't think people should try to use Emacs to build an OS on top of, but building an OS without understanding why Emacs survived is going to just end us up in the same world of inflexible, brittle, clunky software we're in now.

Re:Osm.el – OpenStreetMap Viewer for Emacs by distantsounds on Tuesday March 15, 2022 @10:25AM (#30685705)
Doesn't everyone need geo-locate and map coordinates while simultaneously editing a config file? You're on hackernews, people will come out of the woodwork to defend this stuff.
Re:Osm.el – OpenStreetMap Viewer for Emacs by tmalsburg2 on Tuesday March 15, 2022 @01:33PM (#30688266)
False. Emacs has a wonderful vi(m) implementation in the form of evil-mode.
Re:Osm.el – OpenStreetMap Viewer for Emacs by tuukkah on Tuesday March 15, 2022 @06:01AM (#30683477)
In the future, doing queries and edits within Emacs would be awesome!

Overpass Turbo for queries: https://overpass-turbo.eu/

Level0 for text-based edits: https://wiki.openstreetmap.org/wiki/Level0

Re:Osm.el – OpenStreetMap Viewer for Emacs by deng on Tuesday March 15, 2022 @05:49AM (#30683410)
I just tried it and wow, this works surprisingly great. Pretty snappy, zooming and searching works fine (well, it's using openstreetmap.org for searching, so the results are pretty bad, but that's not the fault of this package).
Re:Osm.el – OpenStreetMap Viewer for Emacs by nicbou on Tuesday March 15, 2022 @11:49AM (#30686812)
This is the beauty of open data and open source in general. No one is forcing you to use the tools as intended. Want a map of all free bathrooms near a café as a markdown file? Knock yourself out! People will even help you do it.

Meanwhile Google Maps has one increasingly user-hostile frontend per platform. It won’t let me see how long a route with waypoints is, and it just started showing me a news feed every time I use it.

OpenStreetMap is as precious as Wikipedia, and very few people seem to realise it.

Re:Osm.el – OpenStreetMap Viewer for Emacs by melling on Tuesday March 15, 2022 @05:21AM (#30683219)
Always fun to see cool things written for the big Lisp interpreter that poses as an editor.

When do those big performance improvements for Emacs Lisp ship?

Re:Osm.el – OpenStreetMap Viewer for Emacs by Tomte on Tuesday March 15, 2022 @05:33AM (#30683317)
nativecomp has already shipped. Is there anything more in the pipeline?
Re:Osm.el – OpenStreetMap Viewer for Emacs by AlbertVAustin on Tuesday March 15, 2022 @05:46AM (#30683394)
Shipped as in "merged to master" but Emacs 28 that will feature this has not been released yet, or am I wrong?
Re:Osm.el – OpenStreetMap Viewer for Emacs by Barrin92 on Tuesday March 15, 2022 @07:57AM (#30684252)
You are right but for what it's worth I've been running the nativecomp build for months now and had exactly zero issues.
Re:Osm.el – OpenStreetMap Viewer for Emacs by seanw444 on Tuesday March 15, 2022 @09:39AM (#30685102)
Huh, I thought it had released already. Been running 28 for about half a year maybe? Works perfectly.
Re:Osm.el – OpenStreetMap Viewer for Emacs by draxil on Tuesday March 15, 2022 @05:49AM (#30683411)
Re:Osm.el – OpenStreetMap Viewer for Emacs by NoGravitas on Tuesday March 15, 2022 @10:21AM (#30685642)
Release branch for Emacs 28 has been cut, but Emacs 28 has not been released yet, no. Emacs main branch is now 29.0.50 now.
Re:Osm.el – OpenStreetMap Viewer for Emacs by Tomte on Tuesday March 15, 2022 @05:51AM (#30683420)
You're right. I've read so much about it that I had stored it as "it's here" in my mind.

Thanks!

Re:Osm.el – OpenStreetMap Viewer for Emacs by mark_l_watson on Tuesday March 15, 2022 @11:27AM (#30686505)
That looks so cool (but I didn’t install it). I regret after 30 years using Emacs that I have mostly moved in to VSCode. I toy with going back to Emacs but I have become addicted to tools like GitHub Copilot that saves me so much time that I can’t imagine not having it always running. Eventually Copilot support will come to Emacs.

Someone else here said that Osm.el is very performant. At its best, Emacs is like a Smalltalk environment where you can happily do all of your work in one environment.

Anyway, I have bookmarked Osm.el and if Copilot becomes available for Emacs I really look forward to spending a day installing both at once.

Re:Osm.el – OpenStreetMap Viewer for Emacs by whartung on Tuesday March 15, 2022 @12:06PM (#30687043)
Very nice. I looked before for some kind of graphics support in Emacs, but didn't find anything. I didn't know that Emacs could render and (I assume) interact with SVG. Apparently it's been in there for some time.

Great, another distraction to tap my time.

Re:Osm.el – OpenStreetMap Viewer for Emacs by sobkas on Tuesday March 15, 2022 @11:58AM (#30686938)
Yep. I also had a phase of "use Emacs for everything, literally" but I have it behind me. I now I use it as the editor. I use it to edit EvEryThIng.
Re:Osm.el – OpenStreetMap Viewer for Emacs by m4lvin on Tuesday March 15, 2022 @06:50PM (#30692991)
This works great, in particular on the Purism Librem 5 :-)
Re:Osm.el – OpenStreetMap Viewer for Emacs by lolcat_cowsay on Tuesday March 15, 2022 @06:05AM (#30683493)
Bloat
Re:Osm.el – OpenStreetMap Viewer for Emacs by seanw444 on Tuesday March 15, 2022 @09:41AM (#30685124)
Bloat is bundling it into the default Emacs distribution. This is cool.
Re:Osm.el – OpenStreetMap Viewer for Emacs by hereforphone on Tuesday March 15, 2022 @10:45AM (#30685957)
RIP "Do one thing and do it well".

"The Unix philosophy is documented by Doug McIlroy in the Bell System Technical Journal from 1978: Make each program do one thing well"

Re:Osm.el – OpenStreetMap Viewer for Emacs by omaranto on Tuesday March 15, 2022 @12:30PM (#30687347)
But that's for individual programs in a larger system. Those of us who live in Emacs do follow the Unix philosophy at the granularity of individual applications inside Emacs or even individual Elisp functions.
Re:Osm.el – OpenStreetMap Viewer for Emacs by Zambyte on Tuesday March 15, 2022 @03:00PM (#30689522)
This is like saying RIP "do one thing and do it well" because Osm.js has been written for Node.js. Osm.el is a program that does one thing well (view OpenStreetMap) for the Emacs runtime.