Whatever it is that you choose to do, follow these two simple rules:
- Be friendly.
- Have fun.
#!/usr/bin/env ruby | |
# CIJoe mail notification script. | |
# Some things in here are shamelessly ripped from | |
# http://gist.github.com/374030 | |
# | |
# Call this from your hooks (build-worked, build-failed) with something like: | |
# ~/ci/scripts/mail.rb ~/ci/PROJECT/ CIJOE_URL BRANCH | |
# | |
# Requirements |
SELECT CONCAT(permission_id, "-", role_id) AS identifier, COUNT(role_id) AS count | |
FROM permissions_roles | |
GROUP BY identifier | |
HAVING count > 1 | |
ORDER BY count; |
namespace :ci do | |
desc "Run all required tasks to perform our build" | |
task :build do | |
RAILS_ENV = ENV['RAILS_ENV'] = 'test' | |
sh "bundle --quiet" | |
Rake::Task["db:migrate"].invoke | |
Rake::Task["db:test:prepare"].invoke | |
Rake::Task["db:seed"].invoke | |
Rake::Task["spec"].invoke | |
RAILS_ENV = ENV['RAILS_ENV'] = 'cucumber' |
de: | |
simple_form: | |
"yes": 'Ja' | |
"no": 'Nein' | |
required: | |
text: 'erfordert' | |
mark: '*' | |
error_notification: | |
default_message: "Es gab folgende Fehler:" |
de: | |
flash: | |
actions: | |
create: | |
notice: "%{resource_name} wurde erfolgreich gespeichert." | |
update: | |
notice: "%{resource_name} wurde erfolgreich bearbeitet." | |
destroy: | |
notice: "%{resource_name} wurde erfolgreich gelöscht." | |
alert: "%{resource_name} konnte nicht gelöscht werden." |
de: | |
errors: | |
messages: | |
not_found: "nicht gefunden" | |
already_confirmed: "wurde bereits bestätigt" | |
not_locked: "war nicht gesperrt" | |
devise: | |
omniauth_callbacks: | |
success: 'Sie wurden erfolgreich eingeloggt.' |
# Helpers | |
def git_update(message) | |
git :add => ".", :commit => "-m '#{message}'" | |
end | |
def git_remove(file) | |
git :rm => file | |
end |
# download and untar nginx | |
wget -O /tmp/nginx.tar.gz http://www.nginx.org/download/nginx-1.0.11.tar.gz | |
tar xzvf /tmp/nginx.tar.gz | |
rm /tmp/nginx.tar.gz | |
# download and untar extra modules | |
wget -O /tmp/nginx-echo-module.tar.gz https://github.com/agentzh/echo-nginx-module/tarball/v0.38rc1 | |
tar xzvf /tmp/nginx-echo-module.tar.gz | |
rm /tmp/nginx-echo-module.tar.gz |
autoload -U colors && colors | |
autoload -Uz vcs_info | |
zstyle ':vcs_info:*' stagedstr '%F{green}●' | |
zstyle ':vcs_info:*' unstagedstr '%F{yellow}●' | |
zstyle ':vcs_info:*' check-for-changes true | |
zstyle ':vcs_info:*' enable git | |
theme_precmd () { | |
if [[ -z $(git ls-files --other --exclude-standard 2> /dev/null) ]] { |