Earlier quoted context omitted.
The code font I use is Triplicate: https://mbtype.com/fonts/triplicate/ I use the Poly variant by default, only disabling it in places where the monospacedness matters for layout purposes, e.g. the terminal recording in this article (because of Vim), and Rust compiler output in some of my other articles. The Poly variant does things like make i, l and space a little narrower, and m a little wider, which makes casual…
I think one of the best reasons to use a monospaced typeface is that it is a fairly strong and accurate signifier of code. Of course, in this case you have special highlighting for it that makes it less useful, but in general I think that it really helps. (Plus there are a couple of other, minor benefits probably not worth listing here.)
Using `make` and `git diff` for a simple and powerful test harness
11–20 of 48 posts
Re: Using `make` and `git diff` for a simple and powerful test harness
#12it's my friday, here's a haiku for you: this is a nice post i'm not sober on hn fixed width code font please
Re: Using `make` and `git diff` for a simple and powerful test harness
#13Earlier quoted context omitted.
In monospace that typeface looks glorious. I'd recommend continuing to use proportional for inline keywords, though.
Interesting. I’ll give the thought time to settle and probably disable Poly for all code blocks tomorrow, leaving it on only for inline code. (That’s what I did initially in the design, but then I decided to make normal code blocks Poly as well because I preferred it so, and why not? —But it seems to be disconcerting people.) Yet one of the things I really like about Poly is how it decreases width. Disabling Poly wou…
Re: Using `make` and `git diff` for a simple and powerful test harness
#14I went to an awful lot of trouble to apply roughly the same technique to test some code generation code [0]. Required pulling in a random dependency and hacking around for a while to make the output look right. Your solution is much slicker! [0]: https://github.com/couchand/wayfinder/blob/1dc58a1130bc17941...
I’m not completely sold on using a separate crate and build.rs how you have, but it looks like it’ll yield a good usable result. A couple of related things you might be interested in: compiletest_rs, trybuild.
Re: Using `make` and `git diff` for a simple and powerful test harness
#15it's my friday, here's a haiku for you: this is a nice post i'm not sober on hn fixed width code font please
As with most poetry jokes, you've worked backwards from the meter to find a line that fits the style but has nothing to do with the rest of the poem.
Please rip out my eyes
I can no longer read this
Polyspaced madnessRe: Using `make` and `git diff` for a simple and powerful test harness
#16I haven't come across this kind of terminal playback on the web before, seems a bit more bandwidth efficient and snappier than video or gifs.
Re: Using `make` and `git diff` for a simple and powerful test harness
#17A bit off-topic, but I like the tty-player you're using for the demo (and apparently have created). https://tty-player.chrismorgan.info/ I haven't come across this kind of terminal playback on the web before, seems a bit more bandwidth efficient and snappier than video or gifs.
The most popular thing in this space nowadays is asciinema, mostly used by embedding it from asciinema.org, but I prefer my thing.
Re: Using `make` and `git diff` for a simple and powerful test harness
#18Re: Using `make` and `git diff` for a simple and powerful test harness
#19 rwildcard = $(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$2) $(filter $2,$d))
is very similar to one I wrote in 2011 (https://blog.jgc.org/2011/07/gnu-make-recursive-wildcard-fun...): rwildcard=$(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$2) $(filter $(subst *,%,$2),$d))
The only difference is that I wanted to be able to use * in the pattern rather than % (hence the subst). $(call rwildcard,,*.c)
vs. $(call rwildcard,,%.c)Re: Using `make` and `git diff` for a simple and powerful test harness
#20Fun. The rwildcard function here rwildcard = $(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$2) $(filter $2,$d)) is very similar to one I wrote in 2011 ( https://blog.jgc.org/2011/07/gnu-make-recursive-wildcard-fun... ): rwildcard=$(foreach d,$(wildcard $1*),$(call rwildcard,$d/,$2) $(filter $(subst *,%,$2),$d)) The only difference is that I wanted to be able to use * in the pattern rather than % (hence the subst).…
Thanks for all the stuff you’ve written about Make: I’ve enjoyed reading quite a lot of it!