HNHacker News
TopNewBestAskShowJobs

clktmr

677 karma · joined April 2, 2019

https://www.timurcelik.de/
submissionscomments
clktmr··on Fibers, Oh My
Another example is Go's runtime.LockOSThread(), which will run a single goroutine exclusively on that thread.
clktmr··on Tridactyl: A Vim-like interface for Firefox
I hesitated long to make qutebrowser my main browser because of lacking password management and device synchronization. Eventually I switched and started using dedicated applications for these tasks.

Qutebrowser is especially great for browsing documentation while coding. Besides it's main point of being keyboard driven, the lack of plugins makes it also absolutely distraction free.

clktmr··on 'Ugh fields', or why you can’t even bear to think about that task
Glad the author mentioned taxes, which are definitely my 'ugh field'. However I already pay a professional to do most of the work, but it doesn't help.
clktmr··on Magit – A Git Porcelain inside Emacs
Not a Magit user, but vim-fugitive. The main reason I prefer it over the CLI is for (un)staging hunks or lines. But I still use the CLI a lot for other stuff.
clktmr··on A word for a value between 0 and 1 (inclusive)
Not true if the value refers to something like RGB color components.
clktmr··on The problem with C
John Carmack wrote in 2010: > There is some decent code in Doom Classic, but it is all C, and I would prefer to do new game development in (restrained) C++.

> I had been harboring some suspicions that our big codebases might benefit from the application of some more of the various �modern� C++ design patterns, despite seeing other large game codebases suffer under them. I have since recanted that suspicion.

I think this shows that C++ works better in controlled (i.e. corporate environments), whereas C is often preferred in Open Source.

clktmr··on Pakistan blocks Tinder, Grindr and other apps
Ok. But this doesn't justify blocking the app by the government, or does it?
clktmr··on Blessed Are the JavaScript Developers
I bet not!

  1 > {} // false
  1 < {} // false
So the result of sorting will be random.

People are fast to complain..

clktmr··on Blessed Are the JavaScript Developers
Well, what would be the expected behavior of sorting an untyped array?
clktmr··on An interesting mistake with Go's context package
> Futures provide pretty much everything that Context does, but without having to thread a magical value correctly through everything.

It has downsides though:

* Instead you have to use async/await throughout your code and suddenly have two execution models that you need to reason about

* Dropping the future won't help if the call is hanging on a blocking call either

* The callee doesn't know anything about a possible deadline

* You can only handle the cancellation in the callee in `Drop`, which gets complicated quickly if you need to rollback changes, because you need to track state manually

* After all the use of 'context' is optional. You only need to pass it if you need cancellation, whereas in async Rust you always need to keep in mind that you might get canceled.

clktmr··on "Rust does not have a stable ABI"
I am using C and Go and I don't remember ever having to deal with some kind of change in the language. Sure there were changes but with very little impact on the ecosystem.

Languages evolve okay, but Rust felt more like it was just right in the making.

clktmr··on "Rust does not have a stable ABI"
> one year is a very long time in rust land

That's the problem and stabilization doesn't solve it. Only rejecting language changes will.

clktmr··on "Rust does not have a stable ABI"
I think the concerns are more towards the ecosystem and community, which are very curiosity-driven. I tried Rust about one year ago and nothing would compile without the nightly toolchain. After reading the Rust book there was this realization that I now have to go and read all the new language proposals, because everybody is using them already. This and the excessive use of metaprogramming by some users drove me away from the language.
clktmr··on File handling in Unix: tips, traps and outright badness
The first half of the article basically complains about the write()'s syscall possibility to fail. Errors can occur and you need to handle them, there is no way around it. Given that "Everything is a File", the OS shouldn't try to make any guarantees around that. There are cases where you want to handle an early return by write().

This is a syscall after all. First priority is to provide a very general interface and remain compatible, not developer ergonomics.

clktmr··on Go 1.15 Released
As far as I understand, it's only about including more information in the compilers json output. But that information was already available in non-json output in previos Go versions.

To get explanations on the optimization decisions by the compiler build your package with:

    go build -gcflags="-m -m"
See also:

    go tool compile -h
    go doc cmd/compile
clktmr··on Take Gitlab to the command line with GLab, an open-source Gitlab CLI tool
Disabling automatic repository housekeeping might help. It can use lots of RAM for large repositories like the Linux kernel.
clktmr··on The Case Against OOP Is Wildly Overstated
> The solution to the fragile base class problem and other inheritance hangovers is surprisingly simple — don’t use it

If OOP provides the footgun to shoot yourself, OOP is at fault. Overall the article reads as "OOP has no problems if is used correctly". Of course that's true. I have seen well designed OOP programs, but the majority was not. The author should ask the question, why OOP is applied the wrong way so often.

clktmr··on Linux Mint drops Ubuntu Snap packages
This is exactly my experience. On top of that snap creates visible directories in $HOME, f-up my loop devices and snap applications can't even access /tmp. Never had any problems with flatpak and appimage. I will however use it solely for proprietary software.
clktmr··on Against Testing
Here I used "UUT" and "component" synonymously, which is simply all the code that should be tested. With behaviour I was referring to expected output for a given input.

There is definitely a lot of cross-talk. Can you make an example where my previous comment would be misguided?

clktmr··on Against Testing
I have seen too many badly written tests, so I tend to agree. Most tests will just fail on any change in the UUT, giving you lots of false positives. This ultimately results in fixing the tests instead of the UUT and blurring the initial intention of the test.

Writing testable code is not about dependency injection etc. It's about having the behaviour of a unit clearly defined. This can be done explicitly in text, but also implicitly by using the component in a certain way. If anything beyond that behaviour is tested, you start to defining the behavior in the testcase. This is fine, but often happens unintentionally leading to a very weird and very specific definition of the behaviour.

For example, I work on a component that generates a configuration. I know that the order of lines of the output doesn't matter and should not matter. But the initial author wrote tests that fail if the order changes, because they just check the output against a string.

clktmr··on Ask HN: Best ways to retain qualified employees?
Personally as a developer I switched jobs multiple times. Most importantly because:

1. I expect to be trusted. If there is no possibility to work from a remote location and excessive time tracking (e.g. punch cards) because of a lack of trust, I realized that my work was not valuated at all.

2. I expect to be able to use my own workflow. If I get micromanaged and am forced to use buggy toolchains and processes with lots of dependencies, my productivity will suffer and so will my passion. Define the inputs and outputs of my work, but not anything in between.

3. Growth is more important than high pay. I am not talking about a 2% raise every year. There really needs to be a difference based on performance. I throw myself into something and get the same pay rise as if I had been slacking the whole year. This will not lower my performance, it will make me leave.

clktmr··on Linus Torvalds: 'I Do No Coding Any More'
You know that 'git blame' exists?
clktmr··on Create Diagrams in VS Code with Draw.io
AFAIK you can do this with the official offline version too.

What's the point of embedding it in vscode especially?

clktmr··on Create Diagrams in VS Code with Draw.io
Isn't this just opening the drawio editor in vscode? What's the point? (genuine question)
clktmr··on Show HN: Rssfs – An RSS reader written as a file system
Not OP, but the benefit of the filesystem implementation is probably to only fetch the data on read.
clktmr··on GitHub Codespaces
I can see why this is interesting from a project manager's perspective. But why would I as a developer want this, let alone pay for it? Isn't this the "developing in a browser" nightmare everybody was joking about a few years ago?

Maybe this will work for developing web applications which are executed on a remote machine by design, but everything else?

clktmr··on Tell HN: C Experts Panel – Ask us anything about C
Why not write is like this:

    #ifdef SOME_CONST
    #define HAS_SOME_CONST \
        ... for SOME_CONST ...
    #else
    #define HAS_SOME_CONST \
        ... when SOME_CONST not defined ...
    #endif
    
    #define WHATEVER(w, h, a, t, e, v, e, r) \
        ... common part ... \
        ... HAS_SOME_CONST ... \
        ... common part continued ...
clktmr··on Things Markdown got wrong
> Doing this basic formatting in ascii text is just mind-numbingly stupid.

Nope, ascii more or less represents your keyboard. Using ascii as user input has zero dependencies. Are you really suggesting some binary encoding for formatting, that is only possible with the respective tooling? I see only disadvantages in that.

clktmr··on Yes, I am still learning Rust
Pretty much what I am thinking. When I use Rust, at the end of the day I will have spent more time with the language instead of my actual task, and I don't see this changing given the rate Rust is still changing. It feels like you have to be a "programming language afficionado" to use Rust properly.

Whereas in Go, there is always only one reasonable way to do a specific task. You almost forget about the language and just get stuff done.

clktmr··on The human body’s remarkable ability to adapt to the cold
Another interesting read about effects of hypothermia is the Dyatlov pass incident:

https://en.m.wikipedia.org/wiki/Dyatlov_Pass_incident

← PreviousPage 4 of 6Next →