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
<!--[if IE]><link rel="shortcut icon" href="path/to/favicon.ico"><![endif]--> | |
<link rel="icon" href="path/to/favicon.png"> |
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
if "_next" in request.POST: | |
return redirect(request.POST.get("_next")) |
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
### Keybase proof | |
I hereby claim: | |
* I am bmelton on github. | |
* I am bmelton (https://keybase.io/bmelton) on keybase. | |
* I have a public key whose fingerprint is D49C 9423 78C7 2FBD 3256 593A 7C7E FA07 0D20 00CB | |
To claim this, I am signing this object: |
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
upstream supportclassrooms { | |
server 127.0.0.1:8003; | |
} | |
upstream socketclassrooms { | |
server 127.0.0.1:8004; | |
} | |
server { | |
listen 80; ## listen for ipv4; this line is default and implied |
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
var App = angular.module('App', [ | |
'linkify', 'ngRoute', 'FixBoolean', 'CompatibilityFilter', 'TierFilter', | |
'RevenueFilter', 'SlugifyFilter', 'FixDateFilter', 'FixCategory', | |
'Help', | |
]) | |
// Define authentication headers for API request | |
var auth_headers = { | |
headers: { | |
'Authorization':'apikey tpui:e54b64ad813c66669467daa110bffb25ba27e829' |
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
module.exports = function(grunt) { | |
grunt.initConfig({ | |
pkg: grunt.file.readJSON('package.json'), | |
concat: { | |
js: { | |
src: [ | |
'static/js/lib/jquery-1.10.2.min.js', | |
'static/js/lib/angular.min.js', | |
'static/js/lib/angular-animate.min.js', | |
'static/js/angular-linkify.min.js', |
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
class StatusViewSet(viewsets.ModelViewSet): | |
def pre_save(self, obj): | |
obj.user = self.request.user | |
def post_save(self, obj, created): | |
if created: | |
parse_links(obj) | |
if obj.send == True: | |
send_tweet(obj) | |
pass |
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
VAGRANTFILE_API_VERSION = "2" | |
Vagrant.configure(VAGRANTFILE_API_VERSION) do |config| | |
config.vm.box = "astral1/saucy64" | |
config.vm.provision :shell, :path => "bootstrap.sh" | |
config.vm.network :forwarded_port, host: 4567, guest: 80 | |
config.vm.synced_folder ".", "/vagrant", type: "rsync", rsync__exclude: ".git/" | |
config.vm.provider "virtualbox" do |vb| | |
end |
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 bash | |
# Update Apt | |
apt-get update | |
# Install necessary things | |
apt-get install software-properties-common python-software-properties python g++ | |
apt-get install -y make | |
apt-get install -y nginx |
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
angular.module('FixDateFilter', []) | |
.filter('fixdate', function() { | |
return function(input) { | |
if(input == null) | |
output = "N/A"; | |
else if(input == "midnight") | |
output = "N/A"; | |
else if(input == "") | |
output = "N/A"; | |
else if(input == "1900-01-01") |