Skip to content

Instantly share code, notes, and snippets.


Arthur Attwell arthurattwell

View GitHub Profile
View gmail-dark.css
/* Extra styles for Gmail applied with Stylus
in combination with Gmail's dark theme
and the Gmail v2 Firefox extension */
/* System fonts for Gmail */
.hx .gD,
.zA > .a4W,
.zA > .xW,
arthurattwell / deploy.bat
Last active Jul 27, 2020
FTP deploy from Windows
View deploy.bat
:: 1. Create a file called secrets.ftp beside this one.
:: 2. Do not commit secrets.ftp to version control.
:: 3. Copy these lines (without the ::s) to it,
:: and add your server IP address, FTP username and FTP password:
:: open 54.454.4.47
:: ftpusernamehere
:: ftppasswordhere
:: cd public_html
:: lcd public
arthurattwell / gmail.css
Last active Feb 11, 2021
Nicer Gmail styles with Stylus, Gmail's dark theme, and [deprecated]
View gmail.css
/* Extra styles for Gmail applied with Stylus
in combination with Gmail's dark theme
and the Firefox extension */
/* Max width on email */
table.Bs.nH.iY.bAt {
max-width: 50em;
margin: auto;
arthurattwell / stylus_basecamp-dark.css
Last active Jun 16, 2021
Dark mode for Basecamp 3 with Stylus
View stylus_basecamp-dark.css
/* Work in progress.
A Basecamp 3 dark theme for Stylus
based on */
--bg-md: #18242b;
--bg-md-2: #152025;
--bg-lt: #213038;

Using Windows Terminal

I've just started using Windows Terminal. Here are tips and settings I'm picking up along the way.

Set default shell

By default WT opens Powershell. I want CMD. Here's how to switch.

arthurattwell /
Created May 4, 2020
Merge someone's fork of your gist into your gist

How to merge someone's fork of your gist into your gist

I created a gist, then someone else forked it and improved it. With a full repository, I might get their improvements in a pull request. But that isn't availabe for gists.

This is how to get their changes into my gist.

  1. Clone your own gist

     git clone
arthurattwell / singular-restricted.php
Created Apr 23, 2020
Sample template-part for Electric Book WP restricted pages
View singular-restricted.php
* The template for displaying single posts and pages,
* adapted as an Electric Book WP page for the Twenty Twenty theme
* @link
* @package WordPress
* @subpackage Twenty_Twenty
* @since Twenty Twenty 1.0
arthurattwell / userChrome.css
Last active Dec 4, 2021
Add numbers to Firefox tabs for easier Ctrl+n tab switching
View userChrome.css
/* userChrome.css can change the Firefox UI.
For details, see
Save it to your Firefox 'Profile Folder'. To find that folder:
enter about:support in the Firefox address bar and look for it in the list.
Save this file to that folder. Then tell Firefox to load it:
enter about:config in the address bar, and search for userprof
and if that setting exists, set the following value to true:
arthurattwell /
Last active Sep 4, 2020
Trigger a GitHub Pages rebuild
# This script will trigger a rebuild on a repo's GitHub Pages site,
# without having to create a new commit.
# To use this script:
# 1. Save this script to an easilyt accessible place, where you'll run it.
# 2. Create a personal access token on GitHub. In Your profile > Settings
# > Developer settings > Personal access tokens
# 3. Save the token in a text file. Idealy, alongside the script as token.txt
# 4. Run the script from the Terminal with ./
arthurattwell /
Last active Jan 21, 2020
Create a files.txt list for an Electric Book project's update folder

Create a files.txt list


dir /a-D /S /B > files.txt

  • To remove .git folder, replace: ^\.git\\.*\n
  • To remove sass-cache, replace: ^\.sass-cache\\.*\n
  • To remove node_modules, replace: ^node_modules\\.*\n
  • To remove _site folder, replace: ^_site\\.*\n