Skip to content

Instantly share code, notes, and snippets.

View stirtingale's full-sized avatar

Stirtingale stirtingale

View GitHub Profile
@robulouski
robulouski / gmail_imap_example.py
Last active April 19, 2024 02:27
Very basic example of using Python and IMAP to iterate over emails in a gmail folder/label. http://www.voidynullness.net/blog/2013/07/25/gmail-email-with-python-via-imap/
#!/usr/bin/env python
#
# Very basic example of using Python and IMAP to iterate over emails in a
# gmail folder/label. This code is released into the public domain.
#
# RKI July 2013
# http://www.voidynullness.net/blog/2013/07/25/gmail-email-with-python-via-imap/
#
import sys
import imaplib
@robulouski
robulouski / gmail_imap_dump_eml.py
Last active April 10, 2024 12:58
Very simple Python script to dump all emails in an IMAP folder to files.
#!/usr/bin/env python
#
# Very simple Python script to dump all emails in an IMAP folder to files.
# This code is released into the public domain.
#
# RKI Nov 2013
#
import sys
import imaplib
import getpass
@martylouis
martylouis / wp-tinyMCE4.php
Created April 23, 2014 22:29
A custom WordPress TinyMCE v4 configuration with styles (now called "Formats") drop down menu and submenus.
<?php
/**
* TinyMCE v4 Config
*
* A custom WordPress TinyMCE v4 configuration with styles (now called "Format") drop down menu with submenus.
*
* style_formats: http://www.tinymce.com/wiki.php/Configuration:style_formats
*
*/
@reganjohnson
reganjohnson / gist:1f6d93c4e3d09e4d5903
Last active March 19, 2018 14:21
Set Default Text Editor as Sublime 3
First, let's create the $ subl command
sudo ln -s "/Applications/Sublime Text.app/Contents/SharedSupport/bin/subl" /usr/local/bin/subl
Another option is to use duti (http://duti.org / https://github.com/moretension/duti).
Run brew install duti, save a file like this as ~/.duti:
com.sublimetext.3 public.plain-text all
com.sublimetext.3 public.unix-executable all
@shazow
shazow / convert-gifs.sh
Last active January 22, 2024 10:13
Batch convert a directory of gifs into mp4
#!/usr/bin/bash
# Convert *.gif into *.mp4, skip if already exists.
outdir="."
for path in *.gif; do
out="${outdir}/${path/.gif/}.mp4"
[[ -f "$out" ]] && continue
ffmpeg -f gif -i "${path}" "${out}"
done
@brettchalupa
brettchalupa / config.yml
Created September 15, 2016 23:33
Shopify Theme Kit config example for screencast (https://www.youtube.com/watch?v=1xWFsYmBoX0)
development:
store: example.myshopify.com
password: add-password-in-config
theme_id: "live"
bucket_size: 40
refill_rate: 2
ignore_files:
- "*.swp"
- "*~"
- "config/settings_data.json"
@LucaCappelletti94
LucaCappelletti94 / MacOs quick setup.md
Last active October 27, 2023 03:17
MacOs commands to get you started.

MacOs quick setup 🚀

Getting everything ready

1 - Xcode/Ruby/Command line tools

You need to have Xcode installed to proceed.

xcode-select --install
sudo xcodebuild -license accept

2 - Brew

@techhahn
techhahn / app.js
Created November 4, 2017 18:58
Smooth Scroll plugin with callback support
var section = document.querySelector('.vs-section')
var smooth = new Smooth({
native: true,
section: section,
ease: 0.1,
callback: function(current) {
console.log(current);
}
});
@ipolyzos
ipolyzos / note_macosx_sublime_default_editor
Created January 16, 2018 18:11
Set sublime 3 as the default editor in MacOSX
## update homebrew
$ brew update
## install duti
brew install duti
## sublimetext 3 default editor for plain text files
duti -s com.sublimetext.3 public.plain-text all
## sublimetext 3 default editor for executable scripts