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
git clone https://github.com/pledgemusic/$1.git $2 | |
cd $2 | |
git submodule init | |
git submodule update | |
cd vendor/gems/pledge_core | |
git checkout master | |
cp .githooks/* ../../../.git/modules/vendor/gems/pledge_core/hooks/ |
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 Project < ActiveRecord::Base | |
class << self | |
def always_attributes | |
%w{attributes anybody can edit} | |
end | |
def draft_attributes | |
%w{available only while project is being written} |
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 Date | |
#hard coded to GB holidays if Holidays gem is installed. | |
def advance_working_days(working_dates_required) | |
return self if working_dates_required == 0 | |
if Gem.available?('holidays') | |
require 'holidays' | |
require 'holidays/gb' | |
end |