Skip to content

Instantly share code, notes, and snippets.

View dotherightthing's full-sized avatar

Dan Smith dotherightthing

  • Do The Right Thing
  • Wellington, New Zealand
View GitHub Profile
@dotherightthing
dotherightthing / scraping-archive-org.md
Last active August 17, 2019 18:53
[Scraping Archive.org] Recovering old web projects. #scraping #waybackmachine #portfolio

Scraping Archive.org

Created: 2017.04.06

  1. Go to the Wayback Machine, enter a URL and take note of the start and end dates for the period where the site snapshots looked a particular way
  2. Download the wayback-machine-downloader
  3. Download the site:
$ cd download-directory
@dotherightthing
dotherightthing / 550-550-5-7-1-spf-check-failed.md
Last active August 15, 2019 10:28
[550 550 5.7.1 SPF check failed] How to stop mail being rejected by the recipient domain. #email

550 550 5.7.1 SPF check failed

Created: 2017.04.06

Background

Two emails have recently bounced back. I realised that both have been rejected by the recipient domain with the same message:

550 5.7.1 Message rejected (SPF)

@dotherightthing
dotherightthing / gist-clients.md
Last active July 27, 2020 21:33
[Gist clients] #gists #github

Gist clients

I'm in the process of moving my knowledgebase of mostly tech notes into Github as gists.

This means that I need good gist clients, so that I can quickly find what I'm looking for.

Note: Gists can only be searched by what's in the Description field. For this reason it's important to add #tags for any keywords that aren't in the 'title'.

Browser

@dotherightthing
dotherightthing / regex.md
Created August 15, 2019 10:57
[Regex] Using Gulp to clean-up scraped HTML. #javascript #gulp
@dotherightthing
dotherightthing / web-developer-toolbar-disable-css.md
Created August 15, 2019 10:58
[Web Developer Toolbar: Disable CSS] #css

Web Developer Toolbar: Disable CSS

Created: 2017.04.02

If the Web Developer toolbar won't disable inline CSS in a local site, check that you are viewing the site through a virtual host URL.

@dotherightthing
dotherightthing / are-you-sure-you-want-to-change-the-extension.md
Created August 15, 2019 11:00
[Are you sure you want to change the extension?] #macos
@dotherightthing
dotherightthing / updating-node-for-es6.md
Last active August 15, 2019 11:04
[Updating Node for ES6] Installing Node.js via an alternate location. #javascript

Updating Node for ES6

Created: 2017.04.05

My call to array.filter( onlyUnique ); was failing. Gulp didn't know what onlyUnique meant.

Unique values in an array offered some ES6 alternatives.

Surely, I thought, Node must have ES6 support built in.

@dotherightthing
dotherightthing / organising-functions-php.md
Created August 15, 2019 11:06
[Organising functions.php] #wordpress
@dotherightthing
dotherightthing / merge-folders-on-os-x-macos.md
Created August 15, 2019 11:13
[Merge folders on OS X / MacOS] #macos
@dotherightthing
dotherightthing / bundling-theme-dependencies.md
Last active August 15, 2019 15:17
[Bundling theme dependencies] #wordpress #tgmpa

Bundling theme dependencies

Created: 2017.03.31

The Composer way is to specify dependencies in composer.json and composer.lock files. Dependencies are then installed via Composer when deploying or working on the site.

The author of this post describes himself as: