Skip to content

Instantly share code, notes, and snippets.

View acolson's full-sized avatar

Aaron Olson acolson

View GitHub Profile
@rbellamy
rbellamy / bitbucket-to-github.rb
Last active October 8, 2024 14:45
Bulk import Bitbucket repos to Github
#!/usr/bin/env ruby
require 'fileutils'
# Originally -- Dave Deriso -- [email protected]
# Contributor -- G. Richard Bellamy -- [email protected]
# If you contribute, put your name here!
# To get your team ID:
# 1. Go to your GitHub profile, select 'Personal Access Tokens', and create an Access token
# 2. curl -H "Authorization: token <very-long-access-token>" https://api.github.com/orgs/<org-name>/teams
# 3. Find the team name, and grabulate the Team ID
@jbreitenbucher
jbreitenbucher / gist:3648028
Created September 5, 2012 23:52
WordPress: Load templates from within a plugin
function get_custom_archive_template($template) {
global $wp_query;
$object = $wp_query->get_queried_object();
if ( 'gslstaff' == $object->post_type ) {
$templates = array();
if ( $object->post_type )
$templates[] = "archive-{$object->post_type}.php";
$templates[] = 'archive.php';