HNHacker News
TopNewBestAskShowJobs

czx4f4bd

653 karma · joined February 9, 2021

submissionscomments
czx4f4bd··on Why 15,000-year-old art may have been displayed in firelight
The Wayback Machine has it: https://web.archive.org/web/20220422124053/https://www.econo...

Here's the actual paper, too: https://journals.plos.org/plosone/article?id=10.1371/journal...

czx4f4bd··on ACM Opens First 50 Years Backfile
Well, shit. I really loved that benefit. I might have to see if my employer will pay for a membership.

Now I have to figure out if there's a way to save all my playlists and notes. Guess I didn't think about the potential downsides of storing all those in a system I don't own.

czx4f4bd··on Vizio TVs are now showing banner ads over live TV
This is what infuriates me the most. I keep thinking about replacing my cheap-ass no-name TV that I've been using for the last 8 years, but the only quality options are all smart TVs and I hate it.

I just loathe the idea of having a TV that (1) is going to have a smartphone-class SoC built-in that I won't even use for anything and (2) is going to be yet another computing device I don't control.

I begrudgingly tolerate the fact that my PS4 and my phone are computers I don't control, because at least they offer functionality that's useful to me, but I draw the line at smart TVs because they aren't even useful in the first place. I'm just going to use my PS4 for everything on it anyway, but then I'll have have another device where I have to worry about software updates and shitty anti-consumer practices.

/rant

czx4f4bd··on RFC 9225: Software Defects Considered Harmful
I think the Red-Green-Refactor loop is pretty close. I learned TDD via obeythetestinggoat.com and it really instilled in me the urge to see a test fail before I trust it when it passes.

Sometimes I forget to check that my test fails the first time, so I’ll go back and deliberately break the function under test just to see it fail.

czx4f4bd··on Hackers Leak Lichess Source Code
Nah, Go sucks. Play Rust instead. Way more fun.
czx4f4bd··on A digital circuit simulator written in sed
Yeah, it was interesting to learn how sed addresses[0] work, particular regex and range addresses in combination.

Basically, you can select a range of lines using regexes. For example, if I wanted to get the text under one header in a Markdown document, I could write something like this:

  sed -n '/^## Overview/,/^#/ { /^#/b; p }' README.md

  - The '-n' flag tells sed not to print all matched lines by default.
  - '/^## Overview/,/^#/' is a range address that matches all lines from
    one starting with "## Overview" to another line starting with "#", inclusive.
  - '{ /^#/b; p }' is a command group that's executed for each matched line.
  - '/^#/b' uses the 'b' (branch) command to skip lines starting with "#" to
    avoid printing the header lines, which are included in the range.
  - Finally, 'p' is the print command, which tells sed to print all the other
    lines.
That said, I mainly read it because I've always used things like Bash's built-in parameter expansion[1] and regex capability[2] instead of sed, and I mostly think I confirmed that bias. I'll probably turn to sed for certain string manipulations from now on, but I'm not sure I'll be using it a whole lot more often.

[0] https://www.gnu.org/software/sed/manual/sed.html#sed-address... [1] https://wiki.bash-hackers.org/syntax/pe [2] https://www.linuxjournal.com/content/bash-regular-expression...

czx4f4bd··on A digital circuit simulator written in sed
I just recently decided to skim the GNU Sed manual and it honestly doesn't surprise me one bit that this is possible. Sed is basically a bytecode VM that only does string manipulation.
czx4f4bd··on I tested four NVMe SSDs from four vendors – half lose FLUSH’d data on power loss
I like how you quoted my question and then completely ignored it. The fact that you disliked the title of a video is not in any way a meaningful criticism of its content.

But okay, let's take a closer look at that video. When I saw it in my YouTube recs, I rolled my eyes at the clickbait and skipped over it, but I didn't see how it makes LTT look bad. In fact, I just gave it a fair shot and skimmed through it for myself, and it actually looks like a pretty solid explanation of memory hierarchy and swap space for beginners, packaged in a format that will increase its reach. I don't see what's bullshit about that.

Look, say what you will about clickbait, the unfortunate truth is that it gets views, which channels like LTT need to survive and grow. Linus is on the record saying he hates it, but they've done the tests to confirm that the stupid thumbnails and titles just perform better.

And come on, let's be honest here: How many people are going to click on a video titled "What is swap space?" or "You can use Google Drive for swap space on Linux" or something similarly boring? Even the best explanation in the world isn't going to get traction with a title like that. I looked for comparable videos and it looks like "What is Linux swap?" by Average Linux User (https://youtu.be/0mgefj9ibRE) is the next most-viewed video on the same topic. That video has gotten about 90,000 views since it was posted in 2019. By comparison, the LTT video has averaged about 100,000 views per day in the 16 days since it was posted.

So it looks to me like LTT took a technical topic that most people would never think about, found an angle to make it interesting to random people browsing YouTube, and tricked potentially thousands of people into learning something. What exactly is embarrassing about that?

czx4f4bd··on I tested four NVMe SSDs from four vendors – half lose FLUSH’d data on power loss
Why do clickbaity thumbnails matter more than the content of the video? Linus has made it clear that he hates using them, but videos with them consistently get way better viewership, which is kinda essential to keep the channel running.

I'm also very curious to see a source on the "bribes he received from Nvidia/Intel", because I'm not finding anything that looks relevant on Google.

czx4f4bd··on Learn Awk with Emacs (2020)
This is one of those things that really irks me about the Unix shell.

You're totally right that commands like `cat *.txt | grep foo` look right and feel intuitive, but the problem is that it's not actually equivalent to `grep foo *.txt`. With a single input file, it's probably not an issue, but with multiple files the downstream command can't actually see what file it's reading from, so in this example grep can't report filenames with matches and you can't use flags like --include/--exclude based on filenames.

I keep wishing for a Unix-like shell and utilities where `cat *.txt | grep foo` actually works the same as `grep foo *.txt`. PowerShell has pulled this off to some extent, which is cool, but it doesn't quite feel right to me compared to Bash.

czx4f4bd··on I recommend CGI instead of web frameworks
How does perl -T protect against XSS?
← PreviousPage 6 of 6