Technical blog of Adam Neumann. Engineer at Gusto in Boulder, CO.
Simple Git Branch Squashing
The old way When developing features, I’ll often use temporary WIP branches to store WIP commits before squashing them into a single feature commit. To squash the WIP commits, I have always run git rebase -i HEAD~x, where x is the number of commits to squash. To calculate x, I run git log and manually count each commit. This week I found a simpler way write that command. A simpler way It turns out that HEAD~x is a commit-ish, which refers to the commit x-1 before HEAD. For trunk based development, HEAD~1 is actually the head of the trunk branch! Conveniently, this commit can also be referred to by the trunk branch’s name. ...
How I Learned "What does the pipe mean in that YAML?"
In this post, I want to talk about a particular experience on a recent project. It started when my pair asked me the straight forward question “What does the pipe mean in that YAML?”. I’ll start with by going over my initial response, then how I caught myself being fearful and prideful, and then how I changed my response to one of honesty and vulnerability. After that, I’ll touch on why this all matters. Finally, I’ll wrap with a summary of some other approaches I use when responding to questions/problems when pairing. ...
Git 101
The problem: Git experience required One common situation I face when working with platform teams is the huge variation in the individuals’ Git experience. Git experience, although common for developers, is far less common for those with more traditional infrastructure or operations backgrounds. And this makes sense, because source control has historically been used by software developers when they write code. “Configuration as code” is still new. The breakdown of experience tends to be something like this: ...
Team Focus
Hello fsharp World
This is where the content would go… More to come soon Stay tuned!
Fixing Slow Spring Boot Startup
TL;DR If you are running MacOS, add hostname (output of hostname) to the IPv4 & IPv6 loopback entries in /etc/hosts to cut 10 seconds from Spring Boot startup time. The Problem Spring Boot has ALWAYS started slow for me. Almost embarrassingly slow. How slow? Start with an empty Spring Boot Web application with Spring Initializer. Now launch the server using ./gradlew bootRun and take a look at that launch time. ...
Launch Spring Boot Application during Fluentlenium test
Recently I had to set up feature tests for a Spring Boot 1.5.6 + Elm web application. For this project I decided to use the Fluentlenium 3.3 framework. It turns out Spring Boot and Fluentlenium work really well together! It always seems harder than it should be to launch web apps for feature tests. Launching background processes, tracking PIDs and killing processes. All I want to do is start the server, run a test, and stop the server. After a little searching, this is how you do just that in Spring Boot and Fluentlenium. ...
Regex Find and Replace in IntelliJ
The other day I was preparing a CSV file for load into a PostgreSQL database. The source file contained a datetime column in an unusual format ('15JUL2017:00:00:00'), which needed to be transformed to a compatible format ('15-JUL-2017:00:00:00') before loading with the \copy CLI command. Values representing many different days, months, and years were present in the thousands. My usual IntelliJ tricks did not work. The file was large (4000 lines), which meant batch editing with multiple carets by matching all occurrences would have been too slow. The pattern itself was easily findable by a regex (2 numeric characters, 3 non-numeric characters, 4 numeric characters), but the replacement string depends on the groups matched. ...