HNHacker News
TopNewBestAskShowJobs

onetom

255 karma · joined October 26, 2009

[ my public key: https://keybase.io/onetom; my proof: https://keybase.io/onetom/sigs/uy9zkyX7ZPfhmaA2RIGTwrDaU0M4zUFBXYVe_UUq4ME ]
submissionscomments
onetom··on The Story Behind Fenster
Would it work on NetBSD/OpenBSD/FreeBSD/GhostBSD too?

Because if it does, it would worth mentioning it in the readme.

In Plan 9, Rio, the window manager, does a similar thing; it exposes a framebuffer to the process running in a window, simply as the /dev/draw device file, iirc.

onetom··on Show HN: Wd-40, a static webserver with automatic hot-reloads
I've settled on devd (modd) for the past few years. https://github.com/cortesi/devd

It's a single file go executable. Supports CORS too. I use it via direnv & nix-shell.

onetom··on RP2350 PicoDVI Preview
what's the fun in that though?

i have the impression, that the main motivation for this project was learning the intricacies of TMDS encoding and providing an open implementation as reference for other ppl, who want to learn too.

there are too many black box electronics these days, so it's very much welcome to virtually open them up, by providing software equivalents of their operation.

onetom··on European crash tester says carmakers must bring back physical controls
Which bus? The CAN bus? :)
onetom··on Show HN: 3 years and 1M users later, I just open-sourced my "Internet OS"
It's hard to make that performant.

As a reference, here is a browser-adapted version of the https://cuis.st/ Smalltalk environment, which does its own rendering onto a canvas:

https://github.com/nmingotti/The-Cuis-CookBook/wiki/Run-Cuis...

onetom··on Show HN: Bitwise Liminal – A Short Film in 256 Bytes of Code
I've also noticed this a few years ago, but where is this documented? Was it already the case in IE6 for example? Have you found any definitive source, which states this behaviour?
onetom··on BYD's YangWang U8 launched, can float on water for 30 minutes and sail 3km/h
I would be cautious believing these stats... How much of those sales are real ones? https://www.youtube.com/watch?v=1SEfwoqKRU8

Their hybrid cars has serious problems, including catching fire on their own. https://www.youtube.com/watch?v=TXrsmYQvK8E

It's not like Tesla didn't have issues, but not so serious and numerous ones.

onetom··on Why do programmers need private offices with doors?
it just sounds like you might have ADHD.

how many browser windows and tabs do you have open usually?

onetom··on KDE Plasma 6.0 Is Enabling Wayland by Default
The built-in Cmd-` (backtick) cycles through the windows of the currently selected app.

I find it better than Context.app, which i did buy and used on a few machines for a few years.

it's like navigating within a sparse table.

columns are the apps, chosen by cmd-tab.

rows are the windows of an app, chosen with cmd-` .

onetom··on Forty years of programming
I've also spent breaks between classes in primary school, at age 6-7, by writing BASIC programs on graph paper. Within a year or 2 I've transitioned to writing in Forth for XZ Spectrum. I used a Roland DX 80 plotter to "print" my source code. I've even sold plotted images from AutoCAD 1.0 for DOS.

I've also learnt Z80 assembly at the same time, coz the "4th Forth by Fébert Csaba for ZX Spectrum" had built-in assembly too.

I've seen my father designing and building a ZX Spectrum clone from scratch. He did explain the process too, so I got to know how a CPU+ALU+RAM+BUS+IO made up a computer.

So I very much consider those years part of my programming career, because they were very much formative and it was a continuum as programming became my career.

Also, don't forget, that all this was cutting edge shit, because there wasn't anything better available for affordable prices for everyday ppl!

even access to the ZX Spectrum was only possible for me, because my father could bring it home from work for the weekends and I could use it a little bit after school, at the University he worked at. my classmates never even saw any kind of computer up close, other than LCD wrist watches...

onetom··on JDK 21 Release Notes
I think these days Clojure is a nicer way to easy into the Java ecosystem, because you can explore existing Java libraries interactively.

Here is a nice demonstration of what can you expect, if you want to build a web app:

https://youtu.be/LcpbBth7FaQ?si=PCZijF-JRmp0xxbz

If you add https://htmx.org/ into the mix, then you can build highly interactive applications, with a lot less complexity compared to building a purely data API consumed by some JavaScript frontend framework (React/Svelte/SolidJS and even ClojureScript)

Also, if you learn Clojure, you get a lot more benefits. Shorter programs, which are easier to reason about and hence easier to maintain, etc.

onetom··on Show HN: Pile Programming Language
Very interesting to see an alternative approach to implementing Clojure! And it's soooo featureful already!

I was just trying to use `Path/of` in the past few days and it took awhile to get familiar with the Clojure varargs interop, so it's nice to see that pile has simple support for it already.

I was also wondering how much the use of more contemporary Java features could enhance the source code or the runtime performance. This implementation seems like a great test-bed for answering such questions.

A small aside: The README uses `Paths/get`, which might be deprecated eventually: https://github.com/openjdk/jdk/blob/b16e5584abcae18fdcc4494f...

Should just use `Path/of` directly.

BTW, I thought I would give it a try, but my initial naive attempt hasn't yielded any results:

     nix shell nixpkgs#maven nixpkgs#jdk20
    Restored session: Wed Sep 20 03:51:47 HKT 2023

    pile on  master is  v0.0.1-SNAPSHOT via  on   (ap-southeast-1) 
     java --version
    openjdk 20.0.2 2023-07-18
    OpenJDK Runtime Environment Zulu20.32+11-CA (build 20.0.2+9)
    OpenJDK 64-Bit Server VM Zulu20.32+11-CA (build 20.0.2+9, mixed mode, sharing)

    pile on  master is  v0.0.1-SNAPSHOT via  v20.0.2 on   (ap-southeast-1) 
     time ./repl             
    [INFO] Scanning for projects...
    [INFO] 
    [INFO] -------------------------< com.pile:pile-lang >-------------------------
    [INFO] Building pile-lang 0.0.1-SNAPSHOT
    [INFO]   from pom.xml
    [INFO] --------------------------------[ jar ]---------------------------------
    [INFO] 
    [INFO] --- clean:3.2.0:clean (default-clean) @ pile-lang ---
    [INFO] Deleting /Users/onetom/github.com/sixfootbeard/pile/target
    [INFO] 
    [INFO] --- resources:3.3.1:resources (default-resources) @ pile-lang ---
    [WARNING] Using platform encoding (UTF-8 actually) to copy filtered resources, i.e. build is platform dependent!
    [INFO] Copying 8 resources from src/main/pile to target/classes
    [INFO] 
    [INFO] --- compiler:3.10.1:compile (default-compile) @ pile-lang ---
    [INFO] Changes detected - recompiling the module!
    [WARNING] File encoding has not been set, using platform encoding UTF-8, i.e. build is platform dependent!
    [INFO] Compiling 294 source files to /Users/onetom/github.com/sixfootbeard/pile/target/classes
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time:  0.358 s
    [INFO] Finished at: 2023-09-20T03:53:30+08:00
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.10.1:compile (default-compile) on project pile-lang: Fatal error compiling: error: release version 20 not supported -> [Help 1]
    [ERROR] 
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
    [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    [ERROR] 
    [ERROR] For more information about the errors and possible solutions, please read the following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
    ./repl  2.37s user 0.18s system 236% cpu 1.075 total
onetom··on Glove80 Ergonomic Keyboard
I couldn't type blind for 30+ years. Never bothered to learn it. Then I used https://www.keybr.com/ a couple of times, less than an hour in total and I was able to touch-type afterwards at an acceptable speed and error rate.

So when I'm experimenting with a new keyboard of key layout, I always practice on keybr.com 1st, because it tremendously speeds up the getting-used-to period!

onetom··on Glove80 Ergonomic Keyboard
where did u map the super key to?
onetom··on Glove80 Ergonomic Keyboard
u mean horizontally staggered doesn't make sense?

ortholinear is the Planck EZ (https://blog.zsa.io/2307-goodbye-planck-ez/) for example.

this Glove80 is vertically staggered (or as they said in the review article: it has column stagger), NOT ortholinear.

onetom··on Glove80 Ergonomic Keyboard
That made me a bit hesitant too, because it's likely that I might not like the switches I choose first.

It takes a few days or weeks of actual usage to have an idea how suitable a certain switch type is.

It's also likely that I would choose different switches for a few keys....

onetom··on Glove80 Ergonomic Keyboard
I'm 46, programming since I was 6 years old and started having wrist and even lower-arm pain ~2-3 years ago. Even the tips of my fingers hurt sometimes.

I never would have imagined I will have such problems...

It's probably the combination of many factors, probably age mostly, but I'm also experimenting with Emacs, with Ctrl being on Caps-Lock and I think that has triggered the problem. Thumb-tip pain is probably from the SpaceFn layout, but the other finger-tips, no idea.

My main keyboard is a Leopold FC M660 with Cherry blues, but IIRC the problems has already started on a stock 60% Cherry MX with linear red switches.

I've also experimented with vegetarian diet for 11 months, which fucked up my guts and ass, plus I always felt super tired, then a beef + potato only diet for 6 months, but that made my joints hurt. Pretty much caused gout, which is also supposed to be worsened by drinking high-fat milk, which I do drink about a liter a day, like I did most of my life. But then the problems has slowly subsided. Not sure what has changed though; I only got older...

onetom··on An excruciatingly detailed guide to SSH (but only the things I find useful)
I grew up on green CGA, goldenrod Hercules monitors and grayscale mono VGA ones.

Indeed, for the past decade I also prefer the light themes, though I find these dark themes pretty usable too: https://protesilaos.com/emacs/modus-themes-pictures

As I've noticed, the main problem with dark themes is the low contrast usually. These modus themes were designed scientifically, to meet the contrast ratios recommended by the Web Content Accessibility Guidelines.

Also, back in those days mono-monitor days, people just kept the brightness at the same level they used during the day and complained how tiring is it for their eyes to "use the computer for so many hours".

My eyes never got tired, because I was constantly adjusting the brightness to match the ambient lighting and I've drastically lowered it, when I was coding in dark.

I've noticed that dark-theme users (eg during live streaming) crank up their brightness/contrast to compensate for the low-contrast dark themes, then they are surprised to be blinded when they open a webpage, which is extremely likely to be light themed and they keep complaining about light themes...

onetom··on WTF is going on with R7RS Large?
Also Clojure decomplects inheritance and interfaces.

It gives you protocols to define a set of related methods, without any restriction on the underlying data structure.

It gives you defrecord & deftype to define composite associative data structures, which the fields in an object are.

Then you can combine these in various ways, giving you all sorts of polymorphic code.

Clojure even has multimethods for cases, when a single operation should happen different ways, depending on some aspect of an arbitrary data structure. Someone defines a transformation function from arbitrary data to some other data to dispatch behavior over, then anyone can add define behavior for new dispatch values.

Why not copy these approaches?

onetom··on WTF is going on with R7RS Large?
too many layers, too much undesirable heritage would be the problem with that, I'd guess
onetom··on Why Tailwind CSS Won
u left out htmx.org ;)
onetom··on Algae powers computer for a year using only light and water (2022)
it compares in physical size. also, it's a visual metaphor.
onetom··on LiteFS Cloud: Distributed SQLite with Managed Backups
The - now free - Datomic (https://www.datomic.com) or the open source XTDB (https://www.xtdb.com) can provide instant access to your data at any point in time. Even to different points in time within a single query, without the concept of a "DB restore" operation.

So if your main use-case of restoring a DB from the past is to run analytical queries on it, then you should probably consider these solutions instead.

These systems rely on other databases to store their data, so they inherit the backup capabilities of those databases.

Would be interesting to consider, if they could benefit from using SQLite as a backend instead of H2DB/DynamoDB/Postgres or RocksDB/LMDB/Xodus/JDBC.

onetom··on Simple Unix Chat
what do i do after i sign up to the-dam.org ? i did not get any email after the payment and ssh-ing doesn't work either. (i just get a `Permission denied (publickey)`)
onetom··on Simple Unix Chat
there are a bunch of features in slack beyond the core chat stuff, like:

1. being connected to multiple communities and switching between them instantly

this can be of course simply replaced by connecting to different servers in a tabbed terminal and use the terminal's built-in cmd-1/2/... shortcut, which happens to be the same as in slack.

2. meta data about others, like their timezone or how to pronounce their name is quite important for distributed team work

this can be approximated by a world readable file on the chat server in every user's home, like .plan or motd files (https://github.com/ESWAT/john-carmack-plan-archive)

3. automatic idleness detection

im actually not sure how reliable is this even in slack, but in general, it can be useful, but im not sure how to solve it elegantly, when the chat runs remotely...

maybe we should just spawn a loop at the background, which gathers idleness status from the OS and uploads it when it changes, into world readable files and the remote clients can just check those file whenever they want.

4. extra status indication with automatic expiry, eg when someone is away from the keyboard, coz they are having lunch

we do use this feature often and it's a really helpful regarding when can we expect a response from someone.

again, quite simple to model this as a plain text file and we can even use emojis, to have a very similar effect to setting " lunch" on slack. ppl would need to know what's the emoji selector shortcut though... like cmd-ctrl-space on macos.

5. text search across all channels/rooms

assuming the chat is being logged into files, then a recursive (rip)grep could work to some extent, but then from the search results one might want to get back to the context of the result too.

6. threads

this complicates implementation a lot more, but we found it an obvious improvement over the single threaded IRC model of communication

7. having threads open on the side, so ppl can track 2 streams of comms at once at least

it would require starting the chat app multiple times and do some window management to see them side-by-side

now obviously all this can be done a lot simpler, but those implementations typically always lack somehow. not sure why is that...

see https://cancel.fm/ripcord/ or http://www.altme.com/what.html

the REBOL 3 programming language even had a quite full featured, text-mode chat built in: http://www.rebol.com/r3/docs/functions/chat.html !

onetom··on Hacker News needs a Dark Mode
what many of those hackers don't realize, it's that their dark mode theme is very hard to read at low brightness levels, so when they switch to some light windows, it pokes their eyes out obviously.

instead of forcing everything to be configured for dark theme, it would be a lot simpler to just drastically lower the brightness at night and keep using light themes.

one trick is to lower the brightness slightly dimmer than comfortable and let your pupils take 2-3 seconds to adapt.

another trick, on iOS/macOS, if you combine this with true tone and night shift, then your eyes will be strained even less!

onetom··on Hacker News needs a Dark Mode
it can be done in pure CSS these days: https://developer.mozilla.org/en-US/docs/Web/CSS/@media/pref...
onetom··on Hacker News needs a Dark Mode
the older i was getting the more i noticed that i can read light mode better than dark mode.

one day, when i was about 42 years old, sitting on a ferry on a very sunny day, i could hardly see my MacBook screen. switched to light mode and while the image was still a bit faint, it became totally readable.

I'm not using anything in dark mode ever since.

onetom··on Hacker News needs a Dark Mode
i didn't know ublock can be used as a poor man's violent monkey :)

i can't read dark mode as well as light mode, but thanks for the advice!

onetom··on Windmill: Open-source developer platform to turn scripts into workflows and UIs
https://babashka.org/ would be great to support.

or maybe just the Small Clojure Interpreter: https://github.com/babashka/SCI if it's a requirement for proper sandboxing

← PreviousPage 2 of 8Next →