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 CreateUsers < ActiveRecord::Migration | |
def change | |
create_table :users do |t| | |
t.string :username, :null => false | |
t.string :lastname | |
t.string :identity | |
t.string :email, :default => nil | |
t.date :birthdate |
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
#!/bin/bash | |
echo "------- Transfer statics pages to Github (make sure jekyll build ok, and git branch dev commited) ---" | |
current_branch=$(git branch | grep '*' | cut -c 3-) | |
echo -e "-- \033[1;33mGit\033[0m : Current branch :\033[0;31m $current_branch\033[0m" | |
if [ $current_branch != "dev" ]; then | |
echo -e "-- \033[0;31mERROR : Branch must be dev \033[0m" |
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
Pry.config.auto_indent = true | |
Pry.config.color = true | |
Pry.config.editor = "vim" | |
#Pry.config.prompt = Pry::DEFAULT_PROMPT | |
Pry.config.history.file = "~/pry_history" | |
Pry.config.hooks.add_hook(:before_session, :say_hi_lazza) do | |
puts "\n\nHi Traz !\nRuby#{RUBY_VERSION}\n\n" | |
end | |
Pry.config.hooks.add_hook(:after_session, :say_bye_lazza) do | |
puts "\n\nbye-bye Traz !\n\n" |
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 AddAttachmentsDataToWrapper < ActiveRecord::Migration | |
def self.up | |
add_column :wrappers, :data_file_name, :string | |
add_column :wrappers, :data_content_type, :string | |
add_column :wrappers, :data_file_size, :integer | |
add_column :wrappers, :data_updated_at, :datetime | |
end | |
def self.down | |
remove_column :wrappers, :data_file_name |