Skip to content

Instantly share code, notes, and snippets.

@gerardroche
gerardroche / date-timezones-by-offset
Last active August 16, 2023 10:48
Timezones by offset
name: Pacific/Kiritimati , cc: KI , offset: 50400 (14 hours) , comments: Line Islands
name: Pacific/Chatham , cc: NZ , offset: 49500 (13.75 hours) , comments: Chatham Islands
name: Pacific/Fakaofo , cc: TK , offset: 46800 (13 hours) , comments:
name: Antarctica/South_Pole , cc: AQ , offset: 46800 (13 hours) , comments: Amundsen-Scott Station, South Pole
name: Antarctica/McMurdo , cc: AQ , offset: 46800 (13 hours) , comments: McMurdo Station, Ross Island
name: Pacific/Tongatapu , cc: TO , offset: 46800 (13 hours) , comments:
name: Pacific/Enderbury , cc: KI , offset: 46800 (13 hours) , comments: Phoenix Islands
name: Pacific/Apia , cc: WS , offset: 46800 (13 hours) , comments:
@gerardroche
gerardroche / sublime-clean
Last active December 17, 2022 06:15
Clean Sublime Text caches and optionally clean out any sessions
#!/bin/sh
set -e
unset CDPATH
unset IFS
show_usage() {
cat <<USAGE
Usage: [PROJECTS_PATH=<PATH>] $(basename "$0") [--exclude-sessions] [--exclude-workspaces]
@gerardroche
gerardroche / exec.py
Created September 23, 2016 15:07
Default/exec.py (Sublime Text 3124 Default Package)
import collections
import functools
import html
import os
import subprocess
import sys
import threading
import time
import sublime
@gerardroche
gerardroche / composer-shim
Last active August 1, 2016 18:57
Script to enable `allow_url_fopen` when running composer on systems where `allow_url_fopen` defaults to off
# 301 https://github.com/gerardroche/dotfiles
@gerardroche
gerardroche / sublime-debug
Last active August 1, 2016 18:57
Run Sublime Text with debug flags
# 301 https://github.com/gerardroche/dotfiles
# 301 https://github.com/gerardroche/dotfiles
# 301 https://github.com/gerardroche/dotfiles
# 301 https://github.com/gerardroche/dotfiles
@gerardroche
gerardroche / gist:cd1dd9cb73b9c84c89f7a0def1ca7779
Last active July 8, 2016 12:08
sublime-generate-package-file-icon-preferences
#!/bin/sh
set -e
unset CDPATH
unset IFS
readonly SOURCE=$(readlink -nf "$0")
readonly SOURCE_PATH=$(dirname "$SOURCE")
readonly SOURCE_NAME=$(basename "$SOURCE")
show_usage() {