Jun. 29, 2016
Ruby on Rails datepicker
Use bootstrap datepicker gem
Gemfile:
gem 'bootstrap-datepicker-rails'
Add this line to app/assets/stylesheets/application.scss
*= require bootstrap-datepicker3
Add this line to app/assets/javascripts/application.js
//= require bootstrap-datepicker
Add this line to template
<%= f.text_field :publish_at, "data-provide" => 'datepicker', "data-date-format" => "yyyy-mm-dd" %>
Aug. 20, 2012
A good tools to manage Pow
According to this post, if you dont need Pow and MAMP Pro together. You can use Powder to run powder down to disable pow first, then start MAMP Pro.
Aug. 7, 2012
This topic is about some general problems when I depoly rails app.
After I set up server environment, I cloned source code by git. Usually, we need do some steps to make sure it works on production environment.
gem we need install
bundle install
initial mongodb
rake db:seed
compile files we need for production
rake assets:precompile --trace RAILS_ENV=production
install javascript runtime
sudo apt-get install nodejs
or from package src
apt-get install make python g++
mkdir ~/nodejs && cd $_
wget -N http://nodejs.org/dist/node-latest.tar.gz
tar xzvf node-latest.tar.gz && cd \`ls -rd node-v*\`
make install