Skip to content

Instantly share code, notes, and snippets.

View akozlik's full-sized avatar

Andrew Kozlik akozlik

View GitHub Profile
@akozlik
akozlik / gist:f6b82cd2779a3fbe7c72
Created April 20, 2015 18:50
Wordpress Search and Replace
// NOTE: All URLs must contain their protocol and must NOT have trailing slashes
// Set the path for all JS / CSS / template imports
update wp_options set option_value = 'new_domain' where option_id in (1, 2)
// Update all links
UPDATE wp_posts SET guid = replace(guid, 'old_url','new_url');
// Replace URL references in post content
UPDATE wp_posts SET post_content = replace(post_content, 'old_url', 'new_url');
@akozlik
akozlik / multicast.go
Last active August 29, 2015 14:23 — forked from fiorix/gist:9664255
package main
import (
"encoding/hex"
"log"
"net"
"time"
)
const (
@akozlik
akozlik / gist:86dc73a68f6ad9ee86dbc947faf21fd0
Last active December 30, 2018 04:25
Bandersnatch (org 3000)
org 3000
runLoop
pop cn
push bd a,5
bd (hl),a
inc hl
cp 191
jr uk
ld de,5