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
production: | |
adapter: mysql | |
database: my_db | |
username: db_user | |
password: <%= begin IO.read("/home/my_deploy_user/.db") rescue "" 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
## based on the example at: | |
## http://gist.github.com/17371 | |
## | |
## put me in lib/un_haml.rb (in the haml-based project) | |
## | |
## call me on the command line thus: | |
## $ script/runner UnHaml app/views/layouts/application.html.haml | |
## $ script/runner UnHaml */*/*/*.haml | |
## | |
class UnHaml < Haml::Engine |
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 on: | |
# http://www.hackido.com/2010/12/install-ruby-on-rails-on-ubuntu.html | |
# http://thekindofme.wordpress.com/2010/10/24/rails-3-on-ubuntu-10-10-with-rvm-passenger-and-nginx/ | |
# http://ascarter.net/2011/01/02/rails-development-on-ubuntu-10.10.html | |
sudo apt-get update | |
sudo apt-get dist-upgrade | |
sudo apt-get install build-essential | |
sudo apt-get install git-core |
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
# inheritance in yml files: | |
development: &defaults | |
adapter: mysql | |
encoding: utf8 | |
database: acme_development | |
username: root | |
test: | |
<<: *defaults |
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
'script configuration: | |
'the coordinates of each monitor, either of the full screen area or parts of it, need to be specified, ordered from left to right. | |
'to take taskbars and desktop toolbars into account when maximizing or moving a window, specify the workspace coordinates instead of | |
'the screen coordinates. both types of coordinates are shown for each monitor under UltraMon menu > About | |
' | |
'sample script configuration: | |
'two monitors at 1024x768, the first monitor is split in a left and right half, the second monitor isn't split: | |
'MONITORS = Array("0,0,512,768","512,0,1024,768","1024,0,2048,768") | |
Option Explicit |
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
; USAGE: | |
; 1. Install autohotkey. | |
; 2. Install the Firefox extension "CSS Reloader". | |
; 3. Save this script anywhere on your computer. | |
; 4. Open your website in Firefox. | |
; 5. In this script, replace "Expresto - Mozilla Firefox" with the title of the Firefox window you want to auto-refresh. | |
; 6. Run this script, it stays in the backgound. | |
; 7. Edit your website inside your preferred text editor or IDE. | |
; 8. Now, save your work, but instead of ctrl+s, use ctrl+alt+s (or altgr+s) and see Firefox refreshing stylesheets automagically in the background. |
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
# usage: | |
# curl https://gist.github.com/raw/816518/generator.sh | bash -s {APPNAME} {SSH_USER} {SSH_HOST} | |
APP=$1 | |
SSH_USER=$2 | |
SSH_HOST=$3 | |
refinerycms -f $APP | |
cd $APP |
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
# How to re-use the menu partial for a submenu in Refinery CMS >= 0.9.8.5 | |
# header menu (main menu) which hides its children. | |
<%= render :partial => "/shared/menu", | |
:locals => { | |
:dom_id => 'menu', | |
:css => 'menu', | |
:collection => @menu_pages, | |
:hide_children => true | |
} -%> |
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
# shoestring.rb | |
# Rails template | |
# from Judd Kussrow of Octopus Inc | |
# $ rails new Project -Jm http://octopusinc.com/shoestring.rb | |
################################### MAINTENANCE ###### | |
gem 'rails3-generators', :group => 'development' | |
gem 'nifty-generators', :group => 'development' |
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
# $APP=$1 | |
# S3_KEY=$2 | |
# S3_SECRET=$3 | |
# S3_BUCKET=$4 | |
# GEMS=$5 | |
gem install heroku --no-rdoc --no-ri | |
refinerycms $APP --heroku -g aws-s3,refinerycms-inquiries | |
# ,$5 | |
cd $APP |