sudo su -
pecl install xdebug
apt-get install unzip
curl -o /tmp/webgrind-release-1.0.zip https://webgrind.googlecode.com/files/webgrind-release-1.0.zip
unzip /tmp/webgrind-release-1.0.zip -d /srv/app/store/
chown -R vagrant:vagrant /srv/app/store/
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Based off of Sails.js 0.11.1 Blueprints REST API generator | |
*/ | |
Blueprints = { | |
serializeObject: function(){ | |
//js function to create json object out of form data | |
$.fn.serializeObject = function(){ | |
var o = {}; | |
var a = this.serializeArray(); | |
$.each(a, function() { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Your snippets | |
# | |
# Atom snippets allow you to enter a simple prefix in the editor and hit tab to | |
# expand the prefix into a larger code block with templated values. | |
# | |
# You can create a new snippet in this file by typing "snip" and then hitting | |
# tab. | |
# | |
# An example CoffeeScript snippet to expand log to console.log: | |
# |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env ruby | |
# encoding: utf-8 | |
=begin | |
github_toc v0.2.0 | |
Brett Terpstra 2014 | |
<http://brettterpstra.com/2014/07/01/github-toc-service/> | |
Creates a linked table of contents from headers in a GitHub readme | |
Place a [toc] marker in the file to have it automatically replaced with the TOC |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# checks if given parameter is a file | |
# @param string filename | |
# usage: is_file my/path/foo.txt || echo "not a file" | |
is_file(){ | |
[[ -f "$1" ]] && return 0 || return 1 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$username = "your_username"; | |
$password = "your_pass"; | |
$url = 'your_stp_server_url'; | |
// Make our connection | |
$connection = ssh2_connect($url); | |
// Authenticate |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Bypass HOSTS file and DNS and send request directly to IP with specified host name. | |
# Example below sends request to localhost with the host name www.foobar.com. | |
curl -sL -w "%{http_code}\\n" -o /dev/null --insecure --resolve 'www.foobar.com:127.0.0.1' https://www.foobar.com/ |