| Models | Examples |
|---|---|
| Display ads | Yahoo! |
| Search ads |
This file contains hidden or 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
| platform :ios, '5.0' | |
| # Awesome networking | |
| pod 'AFNetworking' | |
| # Backported UICollectionView | |
| pod 'PSTCollectionView' | |
| # Rich text | |
| pod 'TTTAttributedLabel' |
This file contains hidden or 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
| Handlebars.registerHelper('equal', function(lvalue, rvalue, options) { | |
| if (arguments.length < 3) | |
| throw new Error("Handlebars Helper equal needs 2 parameters"); | |
| if( lvalue!=rvalue ) { | |
| return options.inverse(this); | |
| } else { | |
| return options.fn(this); | |
| } | |
| }); |
This file contains hidden or 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
| ## The quick-and-nasty CVE-2013-0156 Heroku inspector! | |
| ## Originally brought to you by @elliottkember with changes by @markpundsack @ Heroku | |
| ## Download and run using: | |
| ## ruby heroku-CVE-2013-0156.rb | |
| `heroku list`.split("\n").each do |app| | |
| app = app.strip | |
| # Some "heroku apps" lines have === formatting for grouping. They're not apps. | |
| next if app[0..2] == "===" |
This file contains hidden or 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 | |
| # | |
| # Proof-of-Concept exploit for Rails Remote Code Execution (CVE-2013-0156) | |
| # | |
| # ## Advisory | |
| # | |
| # https://groups.google.com/forum/#!topic/rubyonrails-security/61bkgvnSGTQ/discussion | |
| # | |
| # ## Caveats | |
| # |
This file contains hidden or 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
| source 'https://rubygems.org' | |
| # The latest version of Ruby | |
| ruby '2.0.0' | |
| # The lastest version of Rails | |
| gem 'rails', '3.2.11' | |
| # Postgres | |
| gem 'pg' |
This file contains hidden or 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
| # Copyright Jehiah Czebotar 2013 | |
| # http://jehiah.cz/ | |
| import tornado.options | |
| import glob | |
| import os | |
| import sqlite3 | |
| import logging | |
| import datetime | |
| import csv |
This file contains hidden or 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
| require 'bundler/capistrano' | |
| # This capistrano deployment recipe is made to work with the optional | |
| # StackScript provided to all Rails Rumble teams in their Linode dashboard. | |
| # | |
| # After setting up your Linode with the provided StackScript, configuring | |
| # your Rails app to use your GitHub repository, and copying your deploy | |
| # key from your server's ~/.ssh/github-deploy-key.pub to your GitHub | |
| # repository's Admin / Deploy Keys section, you can configure your Rails | |
| # app to use this deployment recipe by doing the following: |
In August 2007 a hacker found a way to expose the PHP source code on facebook.com. He retrieved two files and then emailed them to me, and I wrote about the issue:
http://techcrunch.com/2007/08/11/facebook-source-code-leaked/
It became a big deal:
http://www.techmeme.com/070812/p1#a070812p1
The two files are index.php (the homepage) and search.php (the search page)
This file contains hidden or 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
| Steps to install and run PostgreSQL 9.2 using Homebrew (Mac OS X) | |
| (if you aren't using version 9.1.5, change line 6 with the correct version) | |
| 1. launchctl unload -w ~/Library/LaunchAgents/homebrew.mxcl.postgresql.plist | |
| 2. mv /usr/local/var/postgres /usr/local/var/postgres91 | |
| 3. brew update | |
| 4. brew upgrade postgresql | |
| 5. initdb /usr/local/var/postgres -E utf8 | |
| 6. pg_upgrade -b /usr/local/Cellar/postgresql/9.1.5/bin -B /usr/local/Cellar/postgresql/9.2.0/bin -d /usr/local/var/postgres91 -D /usr/local/var/postgres | |
| 7. cp /usr/local/Cellar/postgresql/9.2.0/homebrew.mxcl.postgresql.plist ~/Library/LaunchAgents/ |