Skip to content

Instantly share code, notes, and snippets.

View thinkryan's full-sized avatar

Ryan Dennler thinkryan

  • Centro
  • San José, Costa Rica
View GitHub Profile
@thinkryan
thinkryan / actionlist.vim
Created May 23, 2022 16:52 — forked from zchee/actionlist.vim
IdeaVim actionlist
--- Actions ---
$Copy <M-C>
$Cut <M-X> <S-Del>
$Delete <Del> <BS> <M-BS>
$LRU
$Paste <M-V>
$Redo <M-S-Z> <A-S-BS>
$SearchWeb <A-S-G>
$SelectAll <M-A>
$Undo <M-Z>
@max-sixty
max-sixty / fzf-config.fish
Last active January 11, 2023 06:15
Fish fzf settings & functions
## FZF settings & functions for fish; collected with attribution and modified.
# These rely on `git lg`; from git's config:
# lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset'
# They also rely on the following being installed:
# - bat
# - choose
# - delta
# - exa
# - fd
@itzikbenh
itzikbenh / gulpfile.js
Last active March 29, 2023 17:17
Gulp configuration for my WordPress theme development
/*
Create package.json and install all packages:
1. npm init
2. npm install -g gulp
3. npm install gulp gulp-babel babel-preset-es2015 gulp-concat gulp-csso gulp-rename gulp-sass gulp-uglify gulp-watch browser-sync --save-dev
Expected file structure:
./css/src/*.scss
<?php
/**
* Filter the terms query SQL clauses.
*
* @see 'terms_clauses' filter in get_terms() wp-includes/taxonomy.php
*
* @since 0.1.0
*
* @todo add filter for $allowed_orderby_keys
@zchee
zchee / actionlist.vim
Last active April 19, 2024 13:22
IdeaVim actionlist
--- Actions ---
$Copy <M-C>
$Cut <M-X> <S-Del>
$Delete <Del> <BS> <M-BS>
$LRU
$Paste <M-V>
$Redo <M-S-Z> <A-S-BS>
$SearchWeb <A-S-G>
$SelectAll <M-A>
$Undo <M-Z>
@franz-josef-kaiser
franz-josef-kaiser / ajax.js
Last active May 31, 2022 15:53
AJAX in WordPress. Class based example.
( function( $, plugin ) {
"use strict";
// Working with promises to bubble event later than core.
$.when( someObjectWithEvents ).done( function() {
console.log( 'AJAX request done.' );
} )
.then( function() {
setTimeout( function() {
console.log( 'AJAX requests resolved.' );
@fulippo
fulippo / gist:3986307
Created October 31, 2012 10:26
Query to remove orphaned taxonomy terms from a WordPress DB
-- Replace %s with table prefix
DELETE tr
FROM %s_term_relationships tr
INNER JOIN %s_term_taxonomy tt
ON (tr.term_taxonomy_id = tt.term_taxonomy_id)
WHERE tt.taxonomy != 'link_category'
AND tr.object_id NOT IN (SELECT ID FROM %s_posts);
anonymous
anonymous / index.slim
Created September 11, 2012 22:48
Playing with an icon-based radial control; next step is to add some interactivity and make it spin!
div.bevel
a.center l
div.bezel
ul.dial
li#a a
li#b c
li#c e
li#d j
li#e m