
My bag of tricks – loose notes, design patterns, rules-of-thumb - necrodome
http://gordonbrander.com/pattern/
======
epage
I'm regretting I didn't collect my thoughts like this earlier in my career. I
personally learned and internalized many principles but by the time I was tech
leading and mentoring, they had all fallen to the level of intuition and I
couldn't clearly explain the "why"s of things.

~~~
nextos
That's a personal wiki. I think it's invaluable, and since I started building
mine with org-mode I feel much more accomplished. That's because some tasks'
natural outcome is a knowledge bit, which you can't store otherwise.

In the old times, many Germanic scholars would build a similar thing using
flashcards. It was called a zettelkasten.

~~~
fredsir
How are you using org-mode for this?

I have recently switched all my note-taking and task/todo management to org-
mode, but I'm still figuring out how to use it properly. At the moment, I just
have a personal.org, refile.org and project specific .org files, all kinda
taking the shape of headings with sub-sub-sub-sub-headings inside until there
is either none or some content inside, but a personal wiki, it doesn't feel
like. It feels more like ordered mess, kinda. It's definitely better than
anything I've ever used before.

Any good tips you want to share?

~~~
nextos
That's not an easy question. I think you need to enforce some style guide,
like Wikipedia does.

org-mode is a bit like C++ or LaTeX. I say this as a good thing. It has tons
of features, but you need to choose what to use and what to keep out.

For me, something that works great is to keep all org files in the same
folder, with a flat structure. That includes my task list and my calendar. I
version control everything, except organizational things that change often
instead of growing like articles. I also keep out of version control first
quick drafts of any article.

~~~
fredsir
Thanks for the reply!

------
icc97
Ma [0] was also referenced by Alan Kay when talking about smalltalk messages
[1]:

> The big idea is "messaging" \- that is what the kernal of Smalltalk/Squeak
> is all about (and it's something that was never quite completed in our Xerox
> PARC phase). The Japanese have a small word - ma - for "that which is in
> between" \- perhaps the nearest English equivalent is "interstitial".

[0]:
[http://gordonbrander.com/pattern/ma/](http://gordonbrander.com/pattern/ma/)

[1]:
[http://wiki.c2.com/?AlanKayOnMessaging](http://wiki.c2.com/?AlanKayOnMessaging)

------
apo
_Every game with more than one player becomes a game about the interactions
between those players._

Bill Kerr once said that point of view is worth 80 IQ points. I think the
above statement is a good example.

It's simple enough to seem too trivial to write down. Yet years of work and
failure could stand behind it. All too easy for beginners to ignore and trace
the same frustrating path.

------
AllegedAlec
> Not Rocket Science Rule

I've been trying to introduce this into my current company for as long as I've
been working there, with no success so far, with varying reasons:

\- Unit tests for existing projects often fail \- Unit tests for existing
projects take several minutes to run \- Our current build process cannot be
automated.

Quite frustrating, especially since I've seen a lot of cases where it could've
saved us from near-disasters.

EDIT: I think on the subject of Emergence, the writer has missed one key
point: emergence requires interplay between different levels of the system.

~~~
LandR
> Unit tests for existing projects often fail - Unit tests for existing
> projects take several minutes to run - Our current build process cannot be
> automated.

Same here. Except we have no almost no unit tests because

1) Most of the devs don't know how to write unit tests 2) Most of the devs
don't know hot to write code that is testable, even if they could write the
actual unit tests.

About a year or so ago we had a project that got a few unit tests added to it,
within days they were broken nad failing. The dev just added a
[TestCategory("Blah")] and excluded them from being run...

~~~
AllegedAlec
> Except we have no almost no unit tests because

> 1) Most of the devs don't know how to write unit tests

> 2) Most of the devs don't know hot to write code that is testable, even if
> they could write the actual unit tests.

Sounds really familiar... I'd like to add the following one:

> 3) Cannot make the distinction between code that needs unit testsand code
> that does not need unit tests

~~~
fatoons21
I'm new to development, would you recommend any resource out there that covers
points 1) 2) and 3)? Thanks

~~~
TeMPOraL
I'm _old_ to development, and would like to ask for the same thing. But
something beyond "Pragmatic Unit Testing".

You see, I've read that. I've read one other book on unit tests too, and been
on 2-day long training in TDD, and spent many hours _trying_ to write unit
tests, and yet the skill still eludes me. It's like I have a blind spot there,
because I can't for the best of me figure out how to test most of the code I
write.

In the projects I'm working on, I find roughly 10% of the code to be unit-
testable even in principle. That's the core logic, the tricky parts - like the
clever pathfinding algorithm I wrote for routing arrows in diagrams, or the
clever code that diffs configurations to output an executable changeset (add
this, delete that, move this there...). This I usually write functional-style
(regardless of language), I expect specific inputs and outputs, so I can test
such code effectively. Beyond that, I can also test some trivial utilities
(usually also written in functional style). But the remaining 80-90% of any
program I work on turns out to be a combination of:

\- code already tested by someone else - external dependencies

\- code bureaucracy, which forms vast majority of the program - that is,
including/injecting/managing dependencies, moving data around, jumping through
and around abstraction layer; this I believe is untestable in principle,
unless I'm willing to test _code structure_ itself (technically doable for my
Lisp projects...)

\- the user interface, the other big part, which is also hilariously
untestable, and rarely worth testing automatically, as any regression there
will be immediately noticed and reported by real people

I'm having trouble even imagining how to unit-test the three things above, and
it's not something covered in unit testing books, tutorials or courses I've
seen - they all focus on the basics, like assertions and red-green-refactor,
which are the _dumb part_ of writing test. I'm looking for something for the
difficult part - how to test the three categories of code I mentioned above.

~~~
bcbrown
Have you heard of the ideas in
[https://www.destroyallsoftware.com/screencasts/catalog/funct...](https://www.destroyallsoftware.com/screencasts/catalog/functional-
core-imperative-shell)? Essentially, his position is that it's only worth
unit-testing those tricky bits, and the rest is inherently not worth unit-
testing, because you'll almost-certainly embed the same assumptions you're
attempting to test into the tests themselves.

In other words, I agree with you, but would question why you're even _trying_
to unit-test those other areas that aren't conducive to unit testing.

~~~
TeMPOraL
Yes, I've heard of the idea of functional core, imperative shell. In fact,
that's how I write most code these days. But I don't think I've watched this
talk before, so it just went straight into my todo list.

> _In other words, I agree with you, but would question why you 're even
> _trying_ to unit-test those other areas that aren't conducive to unit
> testing._

Well, other people make funny looks at me when they see how little tests I
write...

No, but honestly, I see so much advocacy towards writing lots of tests, or
even starting with tests, and so I'm trying (and failing) to see the merit of
this approach in the stuff I work on.

> _you 'll almost-certainly embed the same assumptions you're attempting to
> test into the tests themselves._

That was my main objection when I was on a TDD course - I quickly noticed that
my tests tend to structurally encode the very implementation I'm about to
write.

------
mrob
Any single page version? As discussed here recently, "Skim reading is the new
normal"[0], and this version with lots of tiny pages is impossible to skim.

[0]
[https://news.ycombinator.com/item?id=17841431](https://news.ycombinator.com/item?id=17841431)

~~~
dang
We usually moderate pages that are just lists of things, because they're
rarely as interesting as the best single item on the list. But I made an
exception because this one seemed unusual.

~~~
mcqueenjordan
Good judgment. I'm really glad I read this today.

------
csbartus
And this is mine:
[https://morethemes.baby/archives/](https://morethemes.baby/archives/)

~~~
spicytunacone
Lovely design. The first time in a very long time I was just clicking around
just to see what would happen. Captures the playfulness of the old web, but
still modern enough. Works especially great on my rotated monitor whereas the
sidebar background becomes increasingly straining on wider displays.

~~~
csbartus
Thanks :)

That’s the idea ... bring back the joy of blogging and meantime capture and
grow knowledge.

------
brennebeck
This is an awesome archive. Definitely bookmarking and sharing. Thank you.

~~~
emmanueloga_
...you missed "and never getting back to it again" :-p

I suspect the main value of this particular list was actually _producing_ the
list, and mainly for the author's sake.

The presentation is actually pretty, and I'm glad people share their favorite
learning/knowledge resources. But I guess I'm coming mainly from my
frustration of finding so many things interesting but so hard to choose what
to focus my attention on.

~~~
brennebeck
Maybe, actually. But I’ll definitely share with others I’m mentoring or
training while doing such. And I think I will also finally put the time in
collating my version. Thanks (for indirectly inspiring me, heh).

------
chrisweekly
+1 for an awesome personal site. Thanks for sharing! Keep it up! :)

------
icc97
I'm reading through Douglas Engelbart's 'Augmenting Human Intellect' at the
moment. He talks about getting his thoughts down to a similar level, so that
each one is a small note or thought which can be linked together. This seems
similar to what has been implemented on this site.

He talks a lot about 'trails' the people create, so I think the idea is that
you'd be able to take this set of notes and links and integrate it with your
own set.

------
Rainymood
>[http://gordonbrander.com/pattern/start-with-a-
toy/](http://gordonbrander.com/pattern/start-with-a-toy/)

This post reminds me of some PG essay I once read (too lazy to look it up).
Did you use the PG essay as reference material? Because if yes it might be
nice to put some links that served as inspiration for the article?

~~~
VladimirGolovin
I remember reading a book about game design (can't remember the title) that
viewed game design through the concept of 'lenses'. One of the lenses was
"first make a toy, then make a game around it". For example, a ball is a toy,
and football, basketball and volleyball are games.

~~~
meheleventyone
Yeah the book is The Art of Game Design: A Book of Lenses by Jesse Schell. It
seems likely this principle was inspired by the book, the author recommends it
on a different page.

It’s a good book which would also be great as a set of prompt cards IDEO
style.

Edit: On a whim I googled and it does exist as a card deck as well!

~~~
napsterbr
As long as we are here: that book by Jesse Schell is wonderful, I highly
recommend it!

------
LrnByTeach
Thank you for sharing this wonderful personal notes. I have been thinking to
make one for my notes, now I got extra motivation ..

------
wgx
I’ve spent the last year extracting all these kind of learnings (with a UX
bias) out of my brain for a book I’ve written. I wish I’d kept notes as I went
along like this person. Great stuff.

------
pure-awesome
Thanks for this. I've thought of making my own blog (or at least part of it)
in a similar style.

(I've got the blog and the domain set up, I just need to start adding
content).

~~~
xaedes
Just add one single item now.

~~~
extragood
Excellent general life advice

------
cake_42
here's a general rule of thumb: a man whose backlog of books isn't as least 2x
as long as the books read is either (logical or here) a) consistently reading
intellectually shallow or uninteresting things b) not really learning anything
from what is being read.

------
megamindbrian2
[https://en.m.wikipedia.org/wiki/Rule_of_thumb](https://en.m.wikipedia.org/wiki/Rule_of_thumb)

------
conatus
This is very cool.

