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
# define a method to run rake tasks | |
def run_rake(task, options={}, &block) | |
rake = fetch(:rake, 'rake') | |
rails_env = fetch(:rails_env, 'production') | |
command = "cd #{current_path} && #{rake} #{task} RAILS_ENV=#{rails_env}" | |
run(command, options, &block) | |
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
Use this regular expression to convert the exported csv-files from Nykredit to the csv-format required by FreeagentCentral. | |
Use the "convert commas to period", and "Omit headers" option when exporting from Nykredit. | |
Find: ^(\d{2})-(\d{2})-(\d{4});(.+?);(-?.+?);(N|J);(.+?);(\d{2}-\d{2}-\d{4})$ | |
Replace: $1/$2/$3,$5,"$4" |