HNHacker News
TopNewBestAskShowJobs

roylez

172 karma · joined February 23, 2013

submissionscomments
roylez··on Ask HN: Notification Overload
I recently find my solution to this on desktop Linux:

+ The machine has "Do not Disturb" on, forever.

+ My todo is a never ending text file. Every appointments are laid out on previous day with the following format:

  *- 09:00 do something*
+ There is a script that runs periodically that checks updates of my todo file, and creates systemd timers that will trigger "critical" level notifications that are not blocked by "Do not Disturb".

  *systemd-run --user --on-calendar="$trigger_time" --unit=$unit_name sh -c 'paplay "$1" && notify-send -u critical Appointment "$2"' _ "$SOUND" "$title"*
roylez··on Rio Terminal: A hardware-accelerated GPU terminal emulator
The ones that I use the most are designed to reduce context switching, like:

Mutt, personal wiki (fzf searching and neovim editing) and todo (a long never ending markdown file), they all have dedicated shortcut (cmd+m/cmd+z/cmd+d) to open(switch to) their window. These applications, always reside in the first tab with stack layout. For example, I can press cmd+m to switch to mutt (or open it), and press cmd+m again to switch back to the previously focused window.

Depending on which repl is running, I can usually open up vim to edit the line with the same cmd+e shortcut, which sends C-X C-E in bash/zsh, ESC O in iex, C-O in aichat ... Also vertical split in tmux and kitty tab share the same shortcut, cmd+|.

Kitty does not have a command palette, and I use fzf to search some of my frequently used operations and make this my command palette.

roylez··on Rio Terminal: A hardware-accelerated GPU terminal emulator
My kitty configuration has grown too much and I could hardly memorise all the customisations. I use its remote control heavily for my workflow. Before kitty, I usually use xterm or urxvt, which are still cool and fast but I cannot go back to the days without those terminal customisations.
roylez··on Facebook uses Australian adults public photos/posts to train AI, without opt-out
Yandex image has his photo listed literally in the first position. Cool website and idea though.
roylez··on Install Asdf: One Runtime Manager to Rule All Dev Environments
I still prefer asdf. It does the job just fine. Direnv has its own stdlib, which sometimes I find useful, and make is something I have to install anyway.
roylez··on What to do when an airline website doesn't accept your legal name
My legal given name was only two characters, which is quite common for Chinese. Airport self check-in kiosks rejected me a lot, and my hunch told me it should be my first name causing problem so I changed my legal name. And no more rejections from those self check-in machines.
roylez··on Tao Te Ching – Gia-Fu Feng, Jane English Translation (1989)
I started by reading Michael LaFargue version, and it is pretty good delivering a basic understanding of the text. I can understand acient Chinese text pretty well, and the original, somehow still feels different from all these translations, but I guess this does not matter that much to a taoist.
roylez··on Ask HN: What is the most memorable game you played?
The gameplay was too short, but still it was a better game than any Diablo releases later. I still remember the horror when confronting the Butcher for the first time. Butchers from later releases are all boring.

Later I learned to cheat by duplicating stuff with a pile of coins, and the difficulty of the game was lowered so much.

roylez··on Ask HN: Is the internet as we knew it, dead?
I thought about this a while back.

Virtual reality is still reality. The early internet that we experienced in 90s felt so different from real world, because it was a new media and real world powers had not yet expand their influence into it yet, but eventually they will. Censorship, speech control, propaganda, commercialization, etc and etc, everything will be there. To the point the new media/platform/reality becomes no different from outside world.

People are excited about VR technology recently. I am not. It would be the same damn story again.

roylez··on Canonical Launches Ubuntu Pro
`sudo systemctl mask motd-news.timer`
roylez··on You Shouldn't Use Manjaro
Enterprises have different priorities from individual users who use Linux as a "daily driver". The last thing they would like to see is an upgrade disrupting their production, and many of them postpone upgrades unless required to. Enterprise Linux are expected to be predicable and companies like version numbers and golden images, and obviously a rolling release is not good at this. In short, Linux used by enterprises are treated as cattle that require minimum attention, but rolling release distros are like pets, which certainly are more delicate and fancy but at the same time require a lot more effort to care for.

There is no better or worse either way. Each distro has its own target audience. Arch is good as a personal work horse, but to charge money from enterprise users, LTS releases are needed.

roylez··on WTF Nextdoor? Over 130 clicks to disable email and push notifications?
Maybe this should be posted to https://old.reddit.com/r/assholedesign .

It is a waste of time trying to educate assholes, avoid them.

roylez··on Don't trust comments
Yes, rst is more powerful. So powerful that it can cause CVE.
roylez··on Google to turn on activity tracking for many users who turned it off
It is amazing that you still have positive karma.
roylez··on Europe Is Entering a Death Spiral: How Immigrants Can Save It
The title alone makes me laugh.
roylez··on List of games that Buddha would not play
Yudhisthira is not an omnipotent god like Buddha. His story in Mahabharata makes him more human than godlike. He makes a lot of mistakes.
roylez··on List of games that Buddha would not play
Imagine Buddha played a game and lost to his opponent. This would not happen.

If you want to start your own religion, you would not allow this to happen.

roylez··on Privacy-focused search engine DuckDuckGo grew by 46% in 2021
It’s not up to a search engine to decide what is true or false. If they want to play this game, it’s censorship.
roylez··on Privacy-focused search engine DuckDuckGo grew by 46% in 2021
After self-hosting whoogle, I never look back. It’s still google but with a lot of junk removed. Sometimes I have to use yandex though, Google’s results are censored and politically biased anyway.
roylez··on uBlacklist: Blocks specific sites from appearing in Google search results
Self-hosting whoogle, now I should remove this plugin.
roylez··on Plain Text Accounting, a guide to Ledger and friends
Have you tried `ledger xact` command? This helps to create new transactions based on previous ones. I have a small wrapper[1] for this, namely "la", which enables me to do something like "la coles 5" to create a new transaction like previous supermarket transaction with the today as date, same from and to accounts, and $5 as amount. If I want to change something, it could be as complete as "la [YYYY.MM.DD/M.D/D] coles grocery 5 credit". If someone has tens of transactions per day it is very likely they are all similar and only little extra adjustment is needed.

Also I use a credit card for most of my expenses, and there are only a handful of bank transfers per month from my access account. Every first day of the month I pull out last month's credit card statement and log all the transactions. It usually takes less than 30 minutes.

[1]: https://github.com/roylez/dotfiles/blob/master/misc/bin/la

roylez··on The CNAME of the Game: Large-scale Analysis of DNS-based Tracking Evasion
Just updated my AdguardHome's block list. Non tech savvy people are screwed. Honestly, how could the majority win this game even when people surfing HN are scrambling to catch up?
roylez··on Apple redirects Google Safe Browsing traffic through proxy servers in iOS 14.5
Apple makes money selling devices; Google makes money selling targeted ads. Making devices more secure will benefit Apple's business, so is collecting more user data to Google's business.
roylez··on Ask HN: What's are your personal automations?
I use it to automate deploys. Thank you.
roylez··on Moving Away from Travis CI
I use self-hosted Gitlab CI runner with docker. It never misses a beat.
roylez··on Circular Pedestrian Bridge in Lujiazui, China
I have been there several times and I hate it. Circular means more walking to get to the other side.
roylez··on ZSH Aliases
My personal favourite

alias -g NF='./*(oc[1])'

This points to the newest file/dir in my current dir, and it is very easy for me to untar a downloaded file and then cd into it without caring about the name of the file/dir.

tar xf NF; cd NF

roylez··on Application Layering – A Pattern for Extensible Elixir Application Design
This is good stuff and makes me rethink about one of my personal projects.

However, I have reserved opinion about the idea that a module should only access its direct children. More than often, I find modules interact with each other forming a loop, either by direct function calls or by message passing. If having to organize all modules into tree structure, I sometimes find it is hard to decide which modules should act as parents without introducing additional layers of abstraction. Also, what if I would like to pass a message from children to their parent? As according to the article, it is better to make children swappable and do not rely on parents' code, either direct calling parental functions or passing message to parent's pid looks bad, all I can think of is to use an event bus, which is extra complexity. Not to mention after so many abstractions module names could be too long to be clear.

Personally now I am good with parent, children, and siblings talking to each other, beyond these is probably too far. Not every module needs to be swappable, and too much abstraction makes stuff harder to understand and not always easier to maintain. Erlang thrived probably even before TDD was there with its "let it crash" philosophy. I do not mind not having 100% test coverage, as long as every crash scenario has been fixed along the way and possibly test guarded.

roylez··on Show HN: Simple tool to make a habit of exercising
My experience is different here.

Every time when I am about to lose a streak, I would try hard not to be influenced emotionally, and would regard an opportunity to keep my ego in check. I have lost streaks many times, 50+ maybe three times, 100+ one time, and I still feel fine with myself.

Normally I would practice Duolingo in the morning before coffee everyday, like a ritual.

roylez··on Nuclear power is the fastest way to slash greenhouse gas emissions, decarbonize
Interesting this gets quickly downvoted. I totally agree with what he/she says. Screwing up once, then the site is fucked for total human eternity, and you have a no-go zone on the map forever. Afterall, "Anything That Can Possibly Go Wrong, Does".
Page 1 of 3Next →