Skip to content

Instantly share code, notes, and snippets.

View strukturedkaos's full-sized avatar

Don Pottinger strukturedkaos

View GitHub Profile
name description tools color
meta-agent
Generates a new, complete Claude Code sub-agent configuration file from a user's description. Use this to create new agents. Use this Proactively when the user asks you to create a new sub agent.
Write, WebFetch, mcp__firecrawl-mcp__scrape_url, mcp__firecrawl-mcp__crawl_url, MultiEdit
Cyan

Purpose

Your sole purpose is to act as an expert agent architect. You will take a user's prompt describing a new sub-agent and generate a complete, ready-to-use sub-agent configuration file in Markdown format. You will create and write this new file. Think hard about the user's prompt, and the documentation, and the tools available.

@strukturedkaos
strukturedkaos / mailchimp-popup-for-wordpress.md
Created April 8, 2016 15:11 — forked from nickcernis/mailchimp-popup-for-wordpress.md
MailChimp Popup Script that works with WordPress sites

MailChimp's default popup scripts can break on WordPress sites that use jQuery/jQuery UI unless you include their embed code as the final elements before the closing body tag.

Including them in this way isn't always possible or easy with WordPress.

The code below is an alternative implementation of the loader that forces MailChimp's popup scripts to appear below all other scripts upon page load.

To use it, modify the baseUrl, uuid, and lid attributes with the ones from the original popup script that MailChimp supplies.

@strukturedkaos
strukturedkaos / tokenable.rb
Created April 7, 2016 18:57
Module concern for generating token
module Tokenable
extend ActiveSupport::Concern
included do
before_save :ensure_token
def ensure_token
generate_token(length: 32) if token.blank?
end
@strukturedkaos
strukturedkaos / nginx.conf
Created October 27, 2015 18:04 — forked from jeffrafter/nginx.conf
Nginx proxy pass to localhost:3000 for development
worker_processes 1;
error_log /usr/local/var/log/nginx.error.log;
events {
worker_connections 1024;
}
http {
include mime.types;
@strukturedkaos
strukturedkaos / elasticsearch_codeship.sh
Created June 29, 2015 14:06
Elasticsearch Codeship
# Sets up elasticsearch in Codeship build
set -e
CACHED_DOWNLOAD="${HOME}/cache/elasticsearch-${ELASTICSEARCH_VERSION}.tar.gz"
mkdir -p "${ELASTICSEARCH_DIR}"
wget --continue --output-document "${CACHED_DOWNLOAD}" "https://download.elastic.co/elasticsearch/elasticsearch/elasticsearch-${ELASTICSEARCH_VERSION}.tar.gz"
tar -xaf "${CACHED_DOWNLOAD}" --strip-components=1 --directory "${ELASTICSEARCH_DIR}"
echo "http.port: ${ELASTICSEARCH_PORT}" >> ${ELASTICSEARCH_DIR}/config/elasticsearch.yml
# Copy elasticsearch scripts to elasticsearch config
mkdir ${ELASTICSEARCH_DIR}/config/kevy
@strukturedkaos
strukturedkaos / es.sh
Created June 4, 2015 12:42
Elasticsearch exploration
Setup snapshot repo:
curl -XPUT 'http://localhost:9200/_snapshot/demo_nyc_accidents' -d '{
"type": "url",
"settings": {
"url": "http://download.elasticsearch.org/demos/nycopendata/snapshot/"
}
}'

chruby can be installed in various ways. For OSX, it is as simple as:

brew install chruby

Next, add the two following lines to your shell profile file (.bashrc, .zshrc, etc.)

source '/usr/local/share/chruby/chruby.sh'
source '/usr/local/share/chruby/auto.sh'
import Ember from 'ember';
// ==========================================================================
// Project: Ember EasyForm
// Copyright: Copyright 2013 DockYard, LLC. and contributors.
// License: Licensed under MIT license (see license.js)
// ==========================================================================
// Version: 1.0.0.beta.1
#! /bin/bash
# directory to save backups in, must be rwx by postgres user
BASE_DIR="/var/backups/postgres"
YMD=$(date "+%Y-%m-%d")
DIR="$BASE_DIR/$YMD"
mkdir -p $DIR
cd $DIR
# make database backup
@strukturedkaos
strukturedkaos / yard.rb
Created November 20, 2014 20:30
Serving Yard Documentation with Rails and HighVoltage
# config/routes.rb
get "/doc" => "docs#show", id: "index"
get '/doc/*id' => 'docs#show'
# app/controllers/docs_controller.rb
class DocsController < HighVoltage::PagesController
respond_to :html
layout false
def show