HNHacker News
TopNewBestAskShowJobs

dguo

2,284 karma · joined December 30, 2013

https://dannyguo.com

You can reach me at danny@dannyguo.com

[ my public key: https://keybase.io/dannyguo; my proof: https://keybase.io/dannyguo/sigs/C2fFXC5Ko08xHzyJcfsCCYirEvBcPjlRkJBGlgl1ipk ]

submissionscomments
dguo··on Ask HN: Best sleep trackers?
I keep a text log and add entries manually every morning. I add my best guesses for when I actually fell asleep and when I woke up. I also log when I woke up in the middle of the night and for how long.

I'm interested in using a device, but I'm skeptical of the accuracy for data like how long my REM cycle were: https://www.menshealth.com/health/a26932734/sleep-trackers-a...

For just knowing roughly how long I'm sleeping each night (and how consistent my bed and wake times are), my text log has been good enough.

I'm not even sure I should be keeping track at all. As the article points out, it may exacerbate sleeping problems by causing me to worry too much about sleep in the first place.

dguo··on Show HN: Screen – screen sharing for remote work, by the cofounder of Screenhero
Thanks for the reply, and good luck! I'm particularly excited about trying it out since you've already implemented cross-platform support.
dguo··on Show HN: Screen – screen sharing for remote work, by the cofounder of Screenhero
I'm looking forward to trying it out!

I'm surprised by how much attention the name is getting. I don't think I personally know anyone who would use GNU Screen over tmux. And disambiguation doesn't seem hard in this case anyway.

One thing that does mildly concern me is the prospect of Screen just turning out to be another Screenhero in terms of being acquired and then neglected or discontinued. But hopefully that won't happen based on the lessons learned in the founder's post[1].

[1]: https://www.notion.so/Screen-Making-WFH-Work-57df16351a884bc...

dguo··on Show HN: MDAnki – convert Markdown to Anki cards
Thank you so much for adding that Wikipedia link. For years (no exaggeration), I've been trying to remember the term for the problem of forgetting what it was like to not know something. I was never able to come up with the right search query.

And now I'm going to add it to my queue for making Anki cards.

dguo··on Into the Personal-Website-Verse (2019)
https://www.dannyguo.com/

Built with Hugo: https://gohugo.io/

dguo··on Casper Sleep S-1
You are correct: https://fortune.com/2016/04/19/casper-amazon-of-sleep/
dguo··on Citymapper
I use Citymapper whenever I'm in NYC. In my experience, it's much better than Google Maps at providing alternate routes and predicting how long travel will take.

It also has many small touches that add up. My favorite ones are that Citymapper will tell you the optimal subway entrance to enter/exit and even which section of the train (front, middle, or back) to get on based on which one is closest to the exit in your destination stop.

dguo··on Amazon’s plan for Alexa
Ha! Of course they did. Thanks for the link.
dguo··on Amazon’s plan for Alexa
For many years, I've claimed to some of my friends that the goal of Amazon is to get to the point where they can order things for us before we even know that we want them. So Amazon wouldn't even require a confirmation on our part. We'll just come home to the packages that Amazon has decided that we need or want.

This situation raises a whole host of issues, and I'm not claiming it'd be a good thing. It just seems to me like the obvious endgame for Amazon, and I think it perfectly fits the modern ethos of reducing friction and pursuing convenience at all costs, including losing our own agency.

dguo··on Using Firefox for a faster, calmer and distraction-free internet
Good point, but one of the key aspects about Firefox's implementation is that you can have different container tabs within the same window. As far as I know, that's still not possible with Chrome.
dguo··on Using Firefox for a faster, calmer and distraction-free internet
The post briefly mentions multi-account containers[1]. I have loved using them and regard them as a killer feature for Firefox. Very few websites support account switching. Google is probably the best example, and even then, I don't really want to log in to both my personal and work Gmail within the same session. But containers effectively and cleanly enable multiple sessions for all websites.

Like tabs so many years ago, it's the kind of feature that seems obvious in retrospect. I can't think of a hard technical reason why we couldn't have had container tabs a long time ago. I hope mobile and desktop OSes will one day implement the same feature for apps/programs.

Whoever was involved in coming up with the idea and with implementing it, thank you!

[1]: https://support.mozilla.org/en-US/kb/containers

dguo··on We do not use foreign keys (2016)
The association would still exist implicitly in the code that uses the database. The columns could stay the same, and the code could still use the item's hypothetical cart_id column to get the items in a cart.

You lose the explicitness and safety of referential integrity in the database, but it's a trade off that can enable other things, like sharding, as mentioned by the GitHub employee.

dguo··on Ask HN: Google Adsense Alternative?
For programming related websites, CodeFund[1] is an option. I tried both Carbon and CodeFund for one of my websites[2], and CodeFund paid out significantly more.

CodeFund is also open source and seems committed to desirable principles, like not doing any user tracking through cookies.

In a feedback survey, I said that I hope they can one day expand beyond programming websites and become a general alternative to AdSense.

[1]: https://codefund.io/

[2]: https://www.makeareadme.com/

dguo··on Functions: To Split or Not to Split
John Carmack has some thoughts on this issue: http://number-none.com/blow/john_carmack_on_inlined_code.htm...

I personally prefer style C with occasional comments serving as guidelines for the reader.

dguo··on The High Price of Multitasking
In college, one of my computer science professors was giving a lecture in which he explained all the low level things (like setting up the stack) that go into calling a function. Then he compared it to the context switches that occur during multitasking. That comparison has stuck with me ever since. It made me very aware that there's a cost to switching tasks each time you do it.
dguo··on iTerm2 3.3
I haven't tried it myself, but there's the new Windows Terminal if you aren't aware of it.

https://github.com/microsoft/terminal

dguo··on The Elite Club That Rules the Diamond World Is Starting to Crack
I recently purchased a moissanite[1] ring and was very happy that it was a choice. My disillusionment with diamonds started when I read this article[2] on how the industry manufactured demand. The argument against diamonds and for moissanite is succinctly made by http://diamondssuck.com/ (I have no affiliation. I am just grateful that the author made it, and I try to share it as much as possible.)

[1]: https://en.wikipedia.org/wiki/Moissanite

[2]: https://www.theatlantic.com/international/archive/2015/02/ho...

dguo··on Ask HN: What are the “best” codebases that you've encountered?
Yep. For some of the larger projects that I've worked on, I've gotten into the habit of adding folder level READMEs. I don't know if anyone else has benefited from them, but I certainly have myself when I need to remind myself of some context or pitfalls.

Having a sensible folder structure and good folder names is nice, but taking a few minutes to write individual READMEs can make a repo even easier to understand.

dguo··on Uncap - Map Caps Lock to Escape on Windows, Linux, and macOS
After doing this (ctrl on hold and escape on tap) on every system I use, I wrote a blog post with instructions: https://www.dannyguo.com/blog/remap-caps-lock-to-escape-and-...
dguo··on Rust as the New C Part 1: Building and Combining Native Libs into C API
Rob Pike has a great blog post in which he addresses this: https://commandcenter.blogspot.com/2012/06/less-is-exponenti...

"I was asked a few weeks ago, "What was the biggest surprise you encountered rolling out Go?" I knew the answer instantly: Although we expected C++ programmers to see Go as an alternative, instead most Go programmers come from languages like Python and Ruby. Very few come from C++."

He later writes:

"Python and Ruby programmers come to Go because they don't have to surrender much expressiveness, but gain performance and get to play with concurrency.

C++ programmers don't come to Go because they have fought hard to gain exquisite control of their programming domain, and don't want to surrender any of it. To them, software isn't just about getting the job done, it's about doing it a certain way.

The issue, then, is that Go's success would contradict their world view.

And we should have realized that from the beginning. People who are excited about C++11's new features are not going to care about a language that has so much less. Even if, in the end, it offers so much more."

dguo··on Netlify Analytics
I wish the pricing scaled with traffic instead of being a flat rate per site.
dguo··on An Exercise Program for the Fat Web
In my experience, watching videos (YouTube, Twitch, etc.) for longer than a few minutes frequently causes Firefox to overload my CPU and bring my entire system to a crawl.

That is the only major issue I have with Firefox. I still use it as my main browser. For one thing, container tabs are a killer feature.

dguo··on Show HN: Scar – Static websites with HTTPS, a global CDN, and custom domains
Netlify can also be very simple to use. You can literally give them a folder of just HTML, CSS, and JS: https://app.netlify.com/drop
dguo··on Apple introduces 8-core MacBook Pro
Seconded, though I also make my caps lock function as control when held down: https://www.dannyguo.com/blog/remap-caps-lock-to-escape-and-...
dguo··on I got control of my spending with some no-code services and 100 lines of Python
Very cool. Using email notifications to get transaction data is a nice hack. If you do find yourself wanting a more formal API, check out Plaid (https://plaid.com/). I've never used it myself, but I believe the free plan is enough to get your personal transactions.
dguo··on Spaced Repetition
I still manually add context to each card. I want each card to be self-sufficient, even without any tag data.
dguo··on Spaced Repetition
I use a single deck, which seems to be a commonly accepted best practice for Anki because mixing topics is good for learning.

I do tag my cards. For example, if a card is "In HTML, what header should you use to make a website responsive?", I would tag it with "programming," "webdev," and "html." The organization is there, but I haven't actually found a use case for the tags yet.

dguo··on Spaced Repetition
I don't. Everything goes into a single deck so that my review sessions interleave[1] topics.

But if you have cards that you don't find interesting or useful anymore, maybe it'd be better to just delete them.

[1]: https://www.scientificamerican.com/article/the-interleaving-...

dguo··on Spaced Repetition
That could be helpful for some, but personally, I don't use any premade decks because the act of making cards is part of the learning process.
dguo··on Spaced Repetition
I have the same problem once in a while. Here are some things you can try.

1. Slow down your review session. I run into this problem mostly when I lose discipline and start skimming the question.

2. Put more effort into breaking info down into very atomic parts. For complex info, I'll still put in a high-level card, but I'll also put in cards that represent pieces of the info.

3. Add different cards for different methods of recall. I frequently add pairs of cards. For example, I added both "what is Betteridge's law?" and "what adage states that any headline that ends in a question mark can be answered with no?"

← PreviousPage 3 of 9Next →