The long way through Software Craftsmanship

Talk: Simplicity matters

Apr 18, 2015 - 1 minute read - Comments - clojurerich-hickeytalkkeynoterails-conf

I’ve seen this video by Rich Hickey: “Simplicity matters”, taken from Manuel Rivero’s google plus’ site here are my notes: the software is the elephant do more, do it differently, do it better complexity of the elephant is going to dominate what you can do your ability to reason about your program is critical design is about pulling things apart become familiar by learning, trying “We can be creating the exact same programs out of significantly simpler components”.

The Guardian of the Source

Apr 17, 2015 - 2 minute read - Comments - craftsmanshipguardiansourcevalueadded-valuepull-requestclientguardian-of-the-sourcecollaborationanalogysocrasandro-mancuso

Overheard today at the office, while they were discussing the approval of a pull request: [Pull request reviewer] - I’m sorry, can’t approve this: I don’t really agree with this design. Isn’t there an alternative for this? [Pull request author] - [redacted], of course you don’t, you’re the guardian of the source [PR reviewer] - Well, sometimes I’m a bit picky about introducing bad code into our codebase. This has made me think about Gandalf blocking the path of Balrog Demon, shouting “you shall not pass” while on top of the bridge.

Inserting clojure code in octopress

Apr 14, 2015 - 1 minute read - Comments - metaoctopressbloggingcodelispclojure

Inserting this code in the blog: ```clojure (defn all-access[k] (let [{:keys [a b] :as k}] (do a) (do (:b k)))) ``` the octopress processor throws the error: Error: Pygments can't parse unknown language: clojure Error: Run jekyll build --trace for more information. A solution would be to include it as lisp code: ```lisp (defn all-access[k] (let [{:keys [a b] :as k}] (do a) (do (:b k)))) ``` this is an example:

Destructuring as a refactor in Clojure

Apr 14, 2015 - 1 minute read - Comments - clojurerefactordestructuringparallel-change

Manuel has taught us today about the default value while destructuring: The following example illustrates the use of an :as directive to bind a local with the entire map. user=> (def point {:x 5 :y 7}) #'user/point (let [{:keys [x y] :as the-point} point] (println "x:" x "y:" y "point:" the-point)) x: 5 y: 7 point: {:x 5, :y 7} We’ve now seen the :as directive used for both vectors and maps.

Redesign as a new TDD phase

Apr 13, 2015 - 2 minute read - Comments - redesigntddtheory

In the last TDD workshop (experience report here), a conversation with Gary McLean Hall introduced to me this new concept of “Redesign” as a TDD phase. Concept As Gary introduced it to me1, it is a phase that might appear after refactor. It is about changing the outside design without changing the expected behavior. I thought this was also included in the refactor phase. How I do redesign I usually do this “changing of the outside design” by applying a series of refactors 2 to the production code but not changing the test code; using a bridge / adapter to get to the new API from the old one.

Experience report: Test-driven development intensive, by Jason Gorman

Apr 12, 2015 - 8 minute read - Comments - trainingworkshopexperience-reportjason-gormanuktddcrc-cardpair-programming

This is an experience report on Jason Gorman’s “Test-driven development intensive workshop” on the April 11th, 2015 I attended this training in the Greenfell housing & training in South Wimbledon, London SW19 1JZ. The training spanned from 10:00 to 17:00 with a half an hour for lunch plus three or four 10-15 minute pauses. (7 - ,5 - 4 * 12/60 = ~5.7hours = 5 hours 45 minutes) Introduction There were 23 of us, including me.