Skip to content

Instantly share code, notes, and snippets.

View peavers's full-sized avatar
💭
I'm ready. Lets go.

Chris Turner peavers

💭
I'm ready. Lets go.
  • Texas
  • 21:46 (UTC -05:00)
View GitHub Profile
@peavers
peavers / rails_resources.md
Last active August 29, 2015 14:27 — forked from jookyboi/rails_resources.md
Rails-related Gems and guides to accelerate your web project.

Gems

  • Bundler - Bundler maintains a consistent environment for ruby applications. It tracks an application's code and the rubygems it needs to run, so that an application will always have the exact gems (and versions) that it needs to run.
  • rabl - General ruby templating with json, bson, xml, plist and msgpack support
  • Thin - Very fast and lightweight Ruby web server
  • Unicorn - Unicorn is an HTTP server for Rack applications designed to only serve fast clients on low-latency, high-bandwidth connections and take advantage of features in Unix/Unix-like kernels.
  • SimpleCov - SimpleCov is a code coverage analysis tool for Ruby 1.9.
  • Zeus - Zeus preloads your Rails app so that your normal development tasks such as console, server, generate, and specs/tests take less than one second.
  • [factory_girl](h
@peavers
peavers / python_resources.md
Last active August 29, 2015 14:27 — forked from jookyboi/python_resources.md
Python-related modules and guides.

Packages

  • lxml - Pythonic binding for the C libraries libxml2 and libxslt.
  • boto - Python interface to Amazon Web Services
  • Django - Django is a high-level Python Web framework that encourages rapid development and clean, pragmatic design.
  • Fabric - Library and command-line tool for streamlining the use of SSH for application deployment or systems administration task.
  • PyMongo - Tools for working with MongoDB, and is the recommended way to work with MongoDB from Python.
  • Celery - Task queue to distribute work across threads or machines.
  • pytz - pytz brings the Olson tz database into Python. This library allows accurate and cross platform timezone calculations using Python 2.4 or higher.

Guides

@peavers
peavers / css_resources.md
Last active August 29, 2015 14:27 — forked from jookyboi/css_resources.md
CSS libraries and guides to bring some order to the chaos.

Libraries

  • 960 Grid System - An effort to streamline web development workflow by providing commonly used dimensions, based on a width of 960 pixels. There are two variants: 12 and 16 columns, which can be used separately or in tandem.
  • Compass - Open source CSS Authoring Framework.
  • Bootstrap - Sleek, intuitive, and powerful mobile first front-end framework for faster and easier web development.
  • Font Awesome - The iconic font designed for Bootstrap.
  • Zurb Foundation - Framework for writing responsive web sites.
  • SASS - CSS extension language which allows variables, mixins and rules nesting.
  • Skeleton - Boilerplate for responsive, mobile-friendly development.

Guides

$.ajax({
type: 'GET',
url: "http://squandered.org:8080/api",
jsonp: "callback",
dataType: "jsonp",
success: function( response ) {
console.log( response );
}
});
<?php
$finder = Symfony\CS\Finder\DefaultFinder::create()
->exclude('vendor')
->exclude('Tests/resources')
->in(__DIR__);
return Symfony\CS\Config\Config::create()
->level(Symfony\CS\FixerInterface::PSR2_LEVEL)
->fixers(array(
@peavers
peavers / install.sh
Last active October 11, 2016 04:23
Installs docker on a clean ubuntu 14.04 server
!#/bin/bash
# Setup keys and repos
sudo apt-get update
sudo apt-get install apt-transport-https ca-certificates
sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D
echo deb https://apt.dockerproject.org/repo ubuntu-trusty main > /etc/apt/sources.list.d/docker.list
sudo apt-get update
sudo apt-get purge lxc-docker
sudo apt-cache policy docker-engine
import Ember from 'ember';
const {get, set, Component} = Ember;
export default Component.extend({
tagName: "",
classNames: "",
actions: {
customAction(items) {
@peavers
peavers / SSLUtil.java
Created May 24, 2018 23:57
Turn on and off SSL verification.
import javax.net.ssl.*;
import java.security.*;
import java.security.cert.X509Certificate;
/**
* Turn on and off SSL verification. Call `turnOffSslChecking`, then make your request followed by `turnOnSslChecking`
*/
public final class SSLUtil {
@peavers
peavers / firestore-scroll.service.ts
Last active February 3, 2023 15:47
Enables infinite/virtual scrolling with ngx-virtual-scroller and Firestore
import {Injectable} from '@angular/core';
import {BehaviorSubject, Observable} from "rxjs";
import {AngularFirestore} from "@angular/fire/firestore";
import {map, mergeMap, scan, tap, throttleTime} from "rxjs/operators";
import {ChangeEvent} from "ngx-virtual-scroller";
/**
* Enables infinite scrolling with ngx-virtual-scroller and Firestore. Most of the hard work goes to
* https://angularfirebase.com/lessons/infinite-virtual-scroll-angular-cdk.
*
@peavers
peavers / docker-compose.yml
Created February 4, 2019 01:51
Local sonar + postgres setup
version: "3.2"
services:
sonarqube:
image: sonarqube
container_name: sonarqube
ports:
- 9000:9000
networks:
- sonarnet