HNHacker News
TopNewBestAskShowJobs

spit2wind

491 karma · joined September 6, 2022

~twst~
submissionscomments
spit2wind··on Jujutsu worktrees are convenient (2024)
Have you used fossil? If so, what are your thoughts?
spit2wind··on Jujutsu worktrees are convenient (2024)
That's interesting. I consider git the worst software ever written!

I speak specifically of the UI. Obviously the underlying system works. Yet it's totally within reason that the UI has wasted trillions of money and many person years in lost productivity.

Napkin math. It's easy to waste 30 minutes figuring out what the heck is going on after a command didn't work, or explaining what a detached head is to a newbie, or any number of completely avoidable issues were the UI better.

Consider the 26.9 million developers in North America[1]. How does one estimate the average salary across NA? Some in SV make 3x that. Elsewhere, it's conceivable that people make considerably less. Let's just say 100k. That's 100,000÷52÷40=48/hr or 24 per half hour. Anyone with git, I think it's safe to say, has had at least one stupid issue that took 30 minutes because of the UI. That's 26.9×24=645,600,000 monies.

In my experience and what I've seen of anyone who'a used git, 30 minutes is a gross underestimate. And people use git outside of NA. It's easily trillions in waste.

https://en.wikipedia.org/wiki/Software_engineering_demograph...

spit2wind··on Guide to making a CHIP-8 emulator (2020)
I've wondered if there's a good "standard" project a person could use to get up to speed on a new language and get an intuitive sense for working with it. For example, plenty of Java programmers can write a working Python program, but it's not "pythonic".

Would writing a CHIP-8 emulator be such a project? It seems non-trivial, yet not too big, the kind of thing that if you implemented it once, implementing it again in another language would be much faster (apart from the language learning).

spit2wind··on Cross-Compiling Common Lisp to WASM
The main VCS is Fossil! I love seeing projects use Fossil rather than git.
spit2wind··on Everyone in Seattle hates AI
> Bring up AI in a Seattle coffee shop now and people react like you're advocating asbestos.

I don't know who first uses the asbestos analogy, but it's 1000% on point.

I think Cory Doctrow says it best,

"AI is the asbestos we're shoveling into the walls of our society — and our descendants will be digging it out for generations."

I believe that's exactly the language to combat AI hype.

spit2wind··on Surprisingly, Emacs on Android is pretty good
Termux isn't required, unless you want other applications (e.g. git, python, or GCC).

If you do want Termux, a signed and compatible version is provided by the Emacs devs. It should all be in the README (at least it always has been, through various updates, since I started using the Emacs on Android before it was merged into the main branch).

spit2wind··on Surprisingly, Emacs on Android is pretty good
> but Emacs TUI just kind of feels like an afterthought

This reads as a testament to how far the Emacs GUI has progressed!

spit2wind··on Surprisingly, Emacs on Android is pretty good
Emacs lets you remap the volume keys:

  (global-set-key (kbd "<volume-down>") 'fill-paragraph)
You can use the usual C-h k <key> to see what Emacs calls the key.
spit2wind··on Surprisingly, Emacs on Android is pretty good
The menus have all you need. It's not ideal, of course, but it's enough to get you going. Otherwise you can remap the menu and toolbar to your needs.

There are several developer oriented keyboards. I found the Unexpected Keyboard quite good.

This is my Unexpected layout:

  <?xml version="1.0" encoding="utf-8"?>
  <keyboard bottom_row="false" name="Emacs-rev1" script="latin">
    <row>
      <key c="q" sw="1" nw="loc esc"/>
      <key c="w" sw="2" nw="~" ne="\@"/>
      <key c="e" sw="3" nw="!" ne="\#" se="loc €"/>
      <key c="r" sw="4" ne="$"/>
      <key c="t" sw="5" ne="%"/>
      <key c="y" sw="6" ne="^"/>
      <key c="u" sw="7" ne="&amp;"/>
      <key c="i" sw="8" ne="\*"/>
      <key c="o" sw="9" ne="("/>
      <key c="p" sw="0" ne=")"/>
    </row>
    <row>
      <key shift="0.4" c="a" nw="loc tab" ne="`"/>
      <key c="s" ne="loc §" sw="loc ß"/>
      <key c="d"/>
      <key c="f"/>
      <key c="g" ne="-" sw="_"/>
      <key c="h" ne="=" sw="+"/>
      <key c="j" ne="}" nw="{"/>
      <key c="k" nw="[" ne="]"/>
      <key c="l" nw="|" ne="\\"/>
    </row>
    <row>
      <key width="1.5" c="shift" ne="loc capslock"/>
      <key c="z"/>
      <key c="x" ne="loc †"/>
      <key c="c" sw="&lt;"   ne="."/>
      <key c="v" sw="&gt;"   ne=","/>
      <key c="b" sw="\?"     ne="/"/>
      <key c="n" sw=":"      ne=";"/>
      <key c="m" ne="&quot;" nw="'"/>
      <key width="1.5" c="backspace" ne="delete"/>
    </row>
    <row height="0.95">
      <key width="1.7" key0="ctrl" key1="loc switch_greekmath" key2="loc meta" key3="loc switch_clipboard" key4="switch_numeric"/>
      <key width="1.7" key0="alt" key1="loc change_method" key2="fn" key3="switch_emoji" key4="config"/>
      <key width="3.5" key0="space" key7="loc home" key8="loc end"/>
      <key width="1.6" key0="loc compose" key7="up" key6="right" key5="left" key8="down" key1="loc page_up" key3="loc page_down"/>
      <key width="1.5" key0="enter" key1="loc voice_typing" key2="action"/>
    </row>
  </keyboard>
spit2wind··on Surprisingly, Emacs on Android is pretty good
My computer died a few months ago and Emacs on Android has carried me through well. Still able to do development on the go. Amazing, amazing work by the Emacs dev!

The Unexpected Keyboard is a great addition, but even with the stock Android keyboard, it's totally usable. Of course, it helps to add things to menus and remap the volume keys.

You can add buttons to the toolbar with something like:

  (tool-bar-add-item "spell"
                   'eval-last-sexp
                   'eval-last-sexp
                   :help "Eval last sexp")

  (tool-bar-add-item "back-arrow"
                   'xref-pop-marker-stack
                   'xref-pop-marker-stack
                   :help "Previous Definition")

  (tool-bar-add-item "fwd-arrow"
                   'xref-find-definitions
                   'xref-find-definitions
                   :help "Find Definitions")
There are many icons bundled with Emacs that you can reuse: https://cgit.git.savannah.gnu.org/cgit/emacs.git/tree/etc/im...

You can remove toolbar buttons:

  (tool-bar-add-item-from-menu 'find-file "")
Otherwise, you can add to menus:

  (define-key global-map
            [menu-bar edit expand]
            '("Expand word" . dabbrev-expand))
Remapping the volume keys is super handy, especially when you change the behavior by mode or buffer:

  (global-set-key (kbd "<volume-down>") 'fill-paragraph)

  (global-set-key (kbd "<volume-up>") 'my-runner)

  (defun my-runner ()
  (interactive)
  (cond ((equal major-mode 'org-mode)
         (call-interactively (local-key-binding (kbd "C-c C-c"))))
        ((equal major-mode 'emacs-lisp-mode)
         (save-buffer)
         (call-interactively 'eval-defun))
        ((string= (my-get-file-name)
                  "/data/data/org.gnu.emacs/files/.emacs.d/my_python_file.py")
         (save-buffer)
         (with-current-buffer (shell "*shell*")
           (my-send-string
            "python /data/data/org.gnu.emacs/files/.emacs.d/my_python_file.py"
            t
            "*shell*")
         ))
        (t
         (message "Undefined action"))
        ))
Redefining the fill column is handy to set appropriate text wrapping:

C-x f runs the command set-fill-column

Otherwise, the menu for Lime Wrapping in this buffer is super helpful.

I set my init to load up Dired so that I'm met with my project directory and am ready to go.

It's hard for me to think of another editor having my back like Emacs has. Again, amazing work by the community!

spit2wind··on Trillions spent and big software projects are still failing
I'm curious, what does "read code" mean to you? What does that skill look like and how is it taught?
spit2wind··on Trillions spent and big software projects are still failing
I heard Direct File was pretty successful. Something like a 94% reported it as a positive experience.
spit2wind··on The Silent Scientist: When Software Research Fails to Reach Its Audience
Glass is great!

The only others who compare are his contemporaries, Steve McConnell, Timothy Lister, Tom DeMarco, and Barry Boehm.

Unfortunately, they're all basically retired. It feels like this kind of interest in software development, at least the publishing, ended around the mid-2000s.

My guess is the shift to blogs from books, adoption of Agile (in whatever form), and a shift in industry focus to getting rich rather than getting good ended the efforts to come up with resources like Glass put together.

spit2wind··on Ask HN: Where to begin with "modern" Emacs?
Open Emacs and press <return> to read the tutorial. This gives you the basics to be productive.

Understandably, some people complain that it shouldn't need a tutorial or the defaults are bad. There's validity to that angle. There's also validity to Emacs pre-dating GUIs, the IBM keyboard, and the x86 instruction set. Once you get past the history of windows and killing, you can explore. The history is also super interesting!

https://www.emacswiki.org/emacs?EmacsHistory

https://dl.acm.org/doi/abs/10.1145/3386324

After you've read the tutorial, go wild. Try stuff out. Break things. Fix them. Learn your limits. Learn that there are very few limits imposed by Emacs itself.

Hands down, the best resource for Emacs is Emacs itself. Especially, the Emacs manual and the Elisp manual. The "An Introduction to Programming in Emacs Lisp" is also excellent if you're not familiar with Lisp. Learn to read Info files and learn the help system (basically C-h f and C-h v)

https://www.gnu.org/software/emacs/manual/

Emacs really is a flagship of Freedom, with all its pain and glory. It lets you exist at the threshold of your zone of proximal development. Every bit you put into Emacs, you get a return on investment.

Welcome to the Emacs community! It's full of weirdos and wizards, as well as regular folk. Stick around and I'm sure you'll make friends in no time.

spit2wind··on PSF has withdrawn $1.5M proposal to US Government grant program
The government was chosen with the majority, yes. That does not mean that the majority should have its way with everything, nor does it mean that everyone, even those who voted in favor at that time agree and approve of current behavior. I mean, why even hold another election if the majority voted for the current administration? Oh wait...
spit2wind··on Scheme Reports at Fifty
This is a good starter. Technically, it's Lisp and not Scheme, but once you understand one, you get the other. The benefit of Emacs Lisp is you can immediately play with it by modifying Emacs to meet your needs.

https://www.gnu.org/software/emacs/manual/eintr.html

spit2wind··on Gem.coop
Really? Maybe I'm naive, but why would .coop be blocked?
spit2wind··on Thoughts on Mechanical Keyboards and the ZSA Moonlander
Steno is 100% the way to go to avoid and heal RSI. Infinitely more ergonomic. It also erases much of the difference between Emacs and VIM (assuming you use repeat and 1up). Yes, it has to be learned. But you already learned Emacs or VIM, so clearly you're not afraid to invest a little now for a big return later (e.g. no RSI). It's also fun.
spit2wind··on As Android developer verification gets ready to go, a new reason to be worried
I was unaware of this book. Thanks for bringing it to my attention!
spit2wind··on EU Chat Control: Germany's position has been reverted to undecided
I see this a lot and am not convinced. It appears reductionist in a way that feels like it's pushing an agenda.

Democratic governments clearly are about addressing community needs and coordinating efforts that require pooled resources (at least). I'm not denying there may be a monopoly on violence. However, in a democratic system, such a monopoly would be voted on, giving the monopoly some legitimacy (not saying it's necessarily moral).

Yet in reality, the US, for example, has the Second Amendment, which grants citizens the right to bear arms and form militias. That doesn't sound like the government has a monopoly on violence.

I guess the weasel word is "legitimate"? But is that legal or moral legitimacy (or something else)? By whose definition and arrived at how?

It feels like such a pithy comment, "a monopoly on legitimate violence", like it's expressing something deep. Yet I get the sense that supporting it requires some contortion of logic and language. Maybe I'm missing something but it doesn't seem self-evident to me at all.

spit2wind··on ChatControl update: blocking minority held but Denmark is moving forward anyway
This is a meme I see and don't fully understand. It seems to assume that the state isn't a democracy, yet the statement is usually applied to democracies like the US. Such statements don't make sense to me when it's the people who are the state, not some "other".
spit2wind··on A beginner's guide to extending Emacs
> (until you're trying to debug some slightly annoying behavior or crufty event loop thing ;)

What do you mean by this? One can look at Emacs itself as a crusty event loop with some slightly annoying behavior. But seriously, I am curious what you mean.

You may already know (and others may not):

- `M-x toggle-debug-on-error` throws you into the debugger on any error (note this isn't "visual" the edebugger!). Use C-h m to see the navigation commands/keys

- Use (debug) to set a breakpoint in Lisp code

- depending on the circumstances, the edebugger may be more helpful. I always instrument the function to debug with `C-u C-M-x` from within the function's form and use `C-M-x` to interpret it (sorry, I forget the underlying commands)

Of course, there's great documentation for both the debugger and edebugger.

spit2wind··on Evolving the OCaml Programming Language (2025) [pdf]
Interesting. I'm still working my way through Correct+Efficient+Beautiful. My takeaway so far has been that Modules _are_ the "O" part of OCaml. I guess there's something more "traditionally" an object? Does that mean there were modules in Caml (or whatever the predecessor was) and it was decided classes might be a good feature to add?
spit2wind··on Removing Guix from Debian
What do you mean by "Just using Guix requires a pretty substantial amount of administrative work."

Like, as a user downloading packages, or a person packaging an application?

As a user downloading a package, it's been super easy for me and it's been years of running Guix with little to no issue (yet the benefits of rolling release, rollbacks, installing multiple versions of a given software etc.).

As for using it to package an application, I found the challenges mainly in the documentation. This was years ago and a lot of work has gone into improving the docs.

I'm curious what your experience has been.

spit2wind··on The United States withdraws from UNESCO
Every bit of resistance counts. If you feel the lat-lon-alt suit your tastes, stick around, speak your mind, and don't let the nationalists tell you to get out. :)
spit2wind··on The United States withdraws from UNESCO
If I may suggest the following edit:

> I really hope a future Congress will undo this fucking mess... otherwise the US is probably never going to catch back up to what it used to be. Voters made a terrible mistake.

Putting too much power into the president is part of the problem.

spit2wind··on Websites hosting major US climate reports taken down
Regarding "persecuted legally", this administration is actively trying to dismantle the rule of law and flouts it.

I appreciate you looking for examples. This podcast episode will give you some, as well as a lens through which you may spot others.

https://www.dancarlin.com/product/common-sense-324-whats-goo...

spit2wind··on The Perils of 'Design Thinking'
> Design won’t save the world. Go volunteer at a soup kitchen, you pretentious fuck

So things like the cotton gin or Ford's use of interchangeable parts don't count as design or somehow didn't change the world?

How is volunteering at soup kitchens more effective at changing the world than interchangeable parts?

And still yet...are you wanting to change the world for the better?

spit2wind··on Define policy forbidding use of AI code generators
Sounds like a teachable moment.

If it's that simple, sounds like you've got your solution! Go ahead and take care of it. If it fits V&V and other normal procedures, like passing tests and documentation, then we'll merge it in. Shouldn't be a problem for you since it will only take a moment.

spit2wind··on The probability of a hash collision (2022)
The author uses writing techniques like those given by Joel Spolsky:

- Rule 1: Be Funny

- Rule 2: Writing a spec is like writing code for a brain to execute

- Rule 3: Write as simply as possible

- Rule 4: Review and reread several times

The author isn't quite as adept at integrating the humor as seemlessly as Joel, yet it's interesting to see how effective the style is, even for someone still learning it. I commend them for making the topic more accessible. It was probably fun to write and was definitely fun to read!

https://www.joelonsoftware.com/2000/10/15/painless-functiona...

← PreviousPage 2 of 7Next →