Blog Archives

Git Bash script to ensure LF before committing

I’m using Git for a big folder of my notes, which I prefer to keep in unix file-format.  Occasionally I’m adding in files that have CRLF, which I could let Git deal with, but I prefer to tidy them before committing, so I wrote a Git Bash one-liner to find them, and wrapped a script around it. Read more ›




reset Dropbox conflicted copies with Windows PowerShell

My Dropbox account was unattached from my Dropbox directory on my netbook for a while, but I updated many text files on my netbook, so that when I re-installed Dropbox, it renamed my changes like this: Read more ›




Pandoc md to pdf with better headings

I keep my notes mostly in one Git’d folder of markdown files, which is vastly quicker and easier than my old WYSIWYG word-processed noting system.  I write and navigate my md’d notes in gVim.  For wide convertablility across markdown engines, I only use markdown headings down to the 4th level.  This was working fine until I put some lyrics directly under a 4th level heading and converted the md file to pdf. Read more ›




A huge Powershell one-liner for Pandoc pdf-ing

So I have a directory containing markdown files, and also subdirectories, and sub-subdirectories, and so on, all containing my markdown files that I keep personal notes in. I find this an incredibly effective system as I can swiftly move around, search and edit these files in gVim. This directory is easily copyable to my smartphones, which can easily open text files in various ways, but sometimes pdf is simpler to open and search on a smartphone. So I would like all of these markdown files to be converted (by Pandoc) to pdf, and I would like to do this from time to time, efficiently. This would be helpful for use on my smartphones but have the added benefit that if I want someone else to access my personal notes, they’d be in both markdown and pdf format, which would be much easier for everyone. Read more ›




Color-highlight selected letters in LaTeX

I intentionally produced my latex leaflet to promote myself as an actor with reduced coloration, but I had an idea to have some letters throughout the text coloured, just to amuse.   My first attempt was to replace all occurances of “et” (French for “and”…) in the text with \textcolor{Red}{et}.  This was fairly quick to do with the power of gVim, and I quite liked the pdf output result, but not the visual mess in the tex file.  I looked for a way to semi-automate it in LaTeX, and found Sh3ljohn’s helpful StackExchange question, which got me thinking that I could colour-highlight these letters throughout my leaflet: J H T j h t. Read more ›




labelling with ImageMagick

I’ve been batch processing hundreds of images, homing in on the most useful ones for my bricoleur ludique website.  My Perl script jpgMagick.pl has proved an exceedingly useful tool. Here, I describe how to create a simple transparent label to add to images. Read more ›




Whitespaces to_underscores

White spaces in file and directory names had never been much of an issue for me until I began doing two new things: using gVim as my note-management tool, and putting up websites.  gVim finds files better if all the paths are without whitespaces, and media files in websites work smoother in general if their names are without whitespaces.  So, I wondered how to create a better workflow for intelligently replacing whitespaces with underscores in Windows 7. Read more ›




Directory Listing for gVim Folded viewing

The problem: do I have that somewhere?

Something that was holding me up organisationally was finding out if I had a film, or a podcast, or some notes somewhere on a disk drive that belongs to me but that’s not connected to my machine, which while I’m writing this is my old netbook. Read more ›




How much of a wizard?

When I describe myself as a “technical wizard”, I feel a little like the Wizard of Oz, but only because all wizardry is only really the possession of a little more skill in a certain area than others. Read more ›