Tech Notes from Benjamin Turner
Extracting Single Files From a Zip
I’ve been working with lots of zip files lately – site backups mostly. Often times this is because of some error message referring to a file contained within the archive. When the zip is quite large, having to extract gigabytes of information just to view the contents of one file is annoying. Because of this […]
Replacing Newlines in Vim Searches
While trying to get a clearer view of a line of text with 5 million characters in it, I ran into some nuances in Vim’s search and replace. The main issue was that replaceing the search string with a newline character – \n wasn’t visually creating a new line in the Vim buffer. I found […]
A few months ago I started to use Spacemacs and org-mode to organize my writing and tasks. Being a Vim user has meant that I haven’t gone all it, but almost.
PDX WordCamp 2017 – Trellis, Bedrock and Roots.io Follow Up
I had a great time last weekend at WordCamp PDX 2017 presenting an overview of Trellis and Bedrock – two Roots.io projects. Here are some notes and follow-up information.
Process for Building a Find Command
While I was setting up logrotate on a server, I needed to traverse a large user directory to find all of the log files, ideally sorted by their size, excluding the mail directory. This is how I built up the command.
Using Unix Date for Bash Filename Timestamp
I’ve started using a neat Bash trick for inserting time stamps into file names — insert a timestamp using command substitution (posix specification): Yes, this is a pain to type out — the first time. But going to the effort of writing this out allows us to quickly recall a command which gives us a filename […]
Clearing PageSpeed Cache Using the Browser
Clearing the PageSpeed cache wasn’t working when logging in as root and ‘touching’ the config file, so I enabled admin access through the browser.
Speaking at WordCamp PDX About Roots.io
The schedule has been finalized for the 2017 PDX WordCamp, happening on September 23rd at Lewis and Clark College. There are a lot of great talks, and I’m glad that I can contribute to the community by sharing my knowledge of managing a WordPress site using the various Roots.io projects. As of right now, all […]
Setting Up Vim to Transparently Work With GPG Files
A quick look at how to setup Vim to transparently create and edit *.gpg files.
WP Asciinema Plugin
I created a plugin called WP Asciinema to help add Asciicasts created using https://asciinema.org/ to WordPress. This is plugin is meant to help self-host asciicasts on your WordPress site. If you are simply wanting to include asciicasts from asciinema.org, then take a look at their embedding guidelines. Usage This plugin adds a shortcode to help display the […]