Skip to content

Instantly share code, notes, and snippets.

Joshua Estes JoshuaEstes

Block or report user

Report or block JoshuaEstes

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@onyxfish
onyxfish / fabfile.py
Created Feb 9, 2010
Chicago Tribune News Applications fabric deployment script
View fabfile.py
from fabric.api import *
"""
Base configuration
"""
env.project_name = '$(project)'
env.database_password = '$(db_password)'
env.site_media_prefix = "site_media"
env.admin_media_prefix = "admin_media"
env.newsapps_media_prefix = "na_media"
View jquery.textchange.js
/*!
* jQuery TextChange Plugin
* http://www.zurb.com/playground/jquery-text-change-custom-event
*
* Copyright 2010, ZURB
* Released under the MIT License
*/
(function ($) {
$.event.special.textchange = {
@bpizzi
bpizzi / gist:669191
Created Nov 9, 2010
Nginx site conf for symfony 1.4
We couldn’t find that file to show.
View 1_Min_Micro_Trading.mq4
//+------------------------------------------------------------------+
//| 1_Min_Micro_Trading.mq4 |
//| StarLimit Software Corps., |
//| starlimit04@yahoo.com |
//+------------------------------------------------------------------+
#property copyright "StarLimit Software Corps.,"
#property link "starlimit04@yahoo.com"
#property indicator_chart_window
@iangreenleaf
iangreenleaf / bitcoin_idle
Created Jun 2, 2011
Bitcoin mining when idle
View bitcoin_idle
#!/bin/bash
# Monitors for signals from gnome-screensaver and activates or deactivates
# bitcoin miners accordingly.
# Params to the mining programs are all hardcoded. Change 'em manually. Leave the "&"s.
dbus-monitor --session "type='signal',interface='org.gnome.ScreenSaver',member='ActiveChanged'" | \
while read line; do
case "$line" in
View gist:1144989
//+------------------------------------------------------------------+
//| LiveAlligator.mq4 |
//| Copyright © 2011, MetaQuotes Software Corp. |
//| http://www.mql4.com/ru/users/rustein |
//-------------------------------------------------------------------+
// Trend Detection function
#define BULL 1
#define BEAR 2
// Input variables
@jubianchi
jubianchi / sf2_standalone_form.php
Created Aug 25, 2011
How to use Symfony2 Form Component Standalone
View sf2_standalone_form.php
<?php
namespace Standalone\Form;
use \Symfony\Component\HttpFoundation as SHttp;
use \Symfony\Component\Form as SForm;
use \Symfony\Component\DependencyInjection as SDI;
use \Symfony\Bridge as SBridge;
//Register all your autoload function here
//...
@lanwin
lanwin / add_users_to_projects.sh
Created Feb 2, 2012
Script to Automatically add all GitLab users to all projects
View add_users_to_projects.sh
#!/bin/sh
baseurl=http://mygitlaburl
usermail=adminuser@mymailserver
userpass=adminpassword
repo_access=2 #0=denied 1=read 2=read&write
project_access=2 #0=deined 1=read 2=report 3=admin
# login
curl -s -I -c cookies.txt -d "utf8=✓&user[email]=$usermail&user[password]=$userpass&commit=Sign+in" $baseurl/users/sign_in
@nijikokun
nijikokun / example-user.js
Created May 3, 2012
Beautiful Validation... Why have I never thought of this before?!
View example-user.js
var user = {
validateCredentials: function (username, password) {
return (
(!(username += '') || username === '') ? { error: "No Username Given.", field: 'name' }
: (!(username += '') || password === '') ? { error: "No Password Given.", field: 'pass' }
: (username.length < 3) ? { error: "Username is less than 3 Characters.", field: 'name' }
: (password.length < 4) ? { error: "Password is less than 4 Characters.", field: 'pass' }
: (!/^([a-z0-9_-]+)$/i.test(username)) ? { error: "Username contains invalid characters.", field: 'name' }
: false
);
@JoshuaEstes
JoshuaEstes / 000-Cheat-Sheets.md
Last active Jun 4, 2019
Developer Cheat Sheets for bash, git, gpg, irssi, mutt, tmux, and vim. See my dotfiles repository for extra info.
You can’t perform that action at this time.