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
| #!/bin/bash | |
| umask 022 | |
| # paranoia settings | |
| # | |
| PATH=/sbin:/bin:/usr/sbin:/usr/bin | |
| export PATH | |
| TARGET="/backup/database" |
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
| #!/bin/bash | |
| aptitude -y install ruby1.8 rubygems1.8 ruby1.8-dev build-essential wget ssl-cert | |
| gem install chef --no-ri --no-rdoc | |
| mkdir -p /etc/chef | |
| cat > /etc/chef/solo.rb <<EOF | |
| file_cache_path "/tmp/chef-solo" | |
| cookbook_path "/tmp/chef-solo/cookbooks" | |
| EOF |
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
| # chiliproject.gems generated gem export file. Note that any env variable settings will be missing. Append these after using a ';' field separator | |
| actionmailer -v2.3.5 | |
| actionpack -v2.3.5 | |
| activerecord -v2.3.5 | |
| activeresource -v2.3.5 | |
| activesupport -v2.3.5 | |
| cgi_multipart_eof_fix -v2.5.0 | |
| daemons -v1.1.0 | |
| edavis10-object_daddy -v0.4.3 | |
| fastthread -v1.0.7 |
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
| foo_path: <%= RAILS_ROOT %>/tmp/foo |
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
| def initialize(*args) | |
| super | |
| @action = :my_default | |
| end |
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 python | |
| import re | |
| import sys | |
| from BeautifulSoup import BeautifulStoneSoup, SoupStrainer | |
| # Documentation is here: | |
| # http://www.crummy.com/software/BeautifulSoup/documentation.html |
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
| #!/path/to/redmine/script/runner | |
| Repository.all.each(&:"destroy!") |
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
| diff --git a/app/controllers/application_controller.rb b/app/controllers/application_controller.rb | |
| index 10c7b65..04ab78b 100644 | |
| --- a/app/controllers/application_controller.rb | |
| +++ b/app/controllers/application_controller.rb | |
| @@ -65,26 +65,32 @@ class ApplicationController < ActionController::Base | |
| def find_current_user | |
| if session[:user_id] | |
| # existing session | |
| - (User.active.find(session[:user_id]) rescue nil) | |
| + user = (User.active.find(session[:user_id]) rescue nil) |
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
| PerlSwitches -T | |
| PerlLoadModule Apache::Redmine | |
| <VirtualHost *:80> | |
| ServerName redmine.server | |
| <Location /svn> | |
| DAV svn | |
| SVNParentPath "/path/to/svn-root" | |
| DirectorySlash Off |
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
| issue = Issue.find(123) | |
| user_who_performs_the_update = User.find(1) | |
| # Initialize the journal entry | |
| note = "I did some updates..." #can also be left blank, i.e. nil | |
| issue.init_journal(user_who_performs_the_update, note) | |
| # Update your stuff here | |
| issue.ac_id = 123 # or whatever |