zoukankan      html  css  js  c++  java
  • install ruby on rails

    -1. build ruby in ubuntu
    http://stackoverflow.com/questions/18490591/how-to-install-ruby-2-on-ubuntu-without-rvm

    0. environment
    Windows 7 sp1 64bit

    1. install ruby

    latest version for windows, 2.0.0-p481 x64
    http://rubyinstaller.org/downloads/

    support that installer folder: c: uby
    add to path: set path=%path%;c: uby

    2. install devkit

    same site as pervious, http://rubyinstaller.org/downloads/
    DevKit-tdm-32-4.5.2-20111229-1559-sfx.exe

    extract to somewhere, e.g. c:devkit
    run: ruby dk.rb init
    will generate config.yml, open the file, find the ruby installation dir, if it is not existing or commented out, add " - c:/ruby"
    NOTICE: the space before and after -.

    run: ruby dk.rb install

    3. install rails

    suppose the installation dir is c: uby
    run: gem install rails

    4. create application

    support that new application dir is c: ewapp
    run: rails new c: ewapp
    run: cd /d c: ewapp
    run: rails server
    if server starts successfully, step 5/6 can be ignored.
    open browser, navigate to http://localhost:3000 to see the welcome page.

    5. update gemfile

    if you face this error "TZInfo::DataSourceNotFound"
    open c: ewappgemfile
    find following lines, if there is not or not the same, add to the gemfile

    # Windows does not include zoneinfo files, so bundle the tzinfo-data gem
    gem 'tzinfo-data', platforms: [:mingw, :mswin, :x64_mingw]

    run: bundle update

    6. start server

  • 相关阅读:
    github
    保存中文文本
    python3与 python2 urllib模块区别
    gitbook 使用粘自csdn
    html基础
    R语言学习笔记之十
    R语言学习笔记之九
    R语言学习笔记之八
    R语言学习笔记之七
    R语言学习笔记之六
  • 原文地址:https://www.cnblogs.com/sadcat/p/3773140.html
Copyright © 2011-2022 走看看