Giter Site home page Giter Site logo

paul-yamamoto / sample_apps Goto Github PK

View Code? Open in Web Editor NEW

This project forked from schoolynk/sample_apps

0.0 1.0 0.0 9.27 MB

Railsチュートリアルの各章が終わった状態を集めたリポジトリです。

Home Page: https://railstutorial.jp/

License: Other

Ruby 69.85% JavaScript 3.79% CoffeeScript 0.72% CSS 1.31% HTML 19.73% Gherkin 0.01% SCSS 4.59%

sample_apps's Introduction

Railsチュートリアル_バナー画像

Rails チュートリアル sample_app コード集

Railsチュートリアルの各章が終わった状態を集めたリポジトリです。

『Railsチュートリアルって何?』という方は公式YouTubeチャンネルをご参照ください 📺 ✨

Sample App の開発途中でエラーの原因がどうしても分からないときや、Railsチュートリアル解説動画を視聴するときなどにご活用ください。(解説動画はお試し視聴もできます)

📂 各章とディレクトリ名の対応関係

対応しているRailsのバージョン毎にディレクトリを分けております。具体的な対応関係は次のとおりです。

上記の各ディレクトリの中に 各章が終わった状態の sample_app を置いています。例えば 5_1_2 ディレクトリの場合は、次のようになります。

  • ch01: 第1章が終わった状態
  • ch02: 第2章が終わった状態
  • ch03: 第3章が終わった状態
  • ch04: 第4章が終わった状態
  • ch05: 第5章が終わった状態
  • ch06: 第6章が終わった状態
  • ch07: 第7章が終わった状態
  • ch08: 第8章が終わった状態
  • ch09: 第9章が終わった状態
  • ch10: 第10章が終わった状態
  • ch11: 第11章が終わった状態
  • ch12: 第12章が終わった状態
  • ch13: 第13章が終わった状態
  • ch14: 第14章が終わった状態

なお、各章の演習の結果や、高度なセットアップなどについては反映されておりません。

✅ 動作環境と注意事項

本リポジトリにあるサンプルコードは AWS Cloud9 上で動作確認しています。macOS や Windows などのローカル環境では下記の手順で動かないこともあります。あらかじめご了承ください。

📜 参考: 「熟練」になるとは - Railsチュートリアル

🔧 アプリを動かす方法

例)第6版の11章を動かす

  1. 本リポジトリをクローンし、該当のディレクトリへ移動します。
$ git clone https://github.com/yasslab/sample_apps.git
$ cd 6_0_0/ch11
  1. 必要なパッケージをインストールし、bundle install(本番環境でのみ必要なgemはスキップ)します。
$ yarn add [email protected] [email protected]
$ bundle install --without production
  1. データベースを移行します。
$ rails db:migrate
  1. テストを実行して、正しく動作していることを確認します。
$ rails test
  1. サンプルユーザーをデータベースにseedして、アプリを実行する準備が整いました。
$ rails db:seed
$ rails server

新しいユーザーを登録するか、メールアドレス[email protected]とパスワード(foobar)を使用してサンプル管理ユーザーとしてログインできます。

🎓 関連リンク/関連レポジトリ

:octocat: 本リポジトリのライセンス

The MIT License

Copyright © 2015-2021 YassLab Inc.

YassLab Logo

:octocat: Sample Appのライセンス

Ruby on Rails Tutorial: Learn Web Development with Rails. Copyright © 2014 by Michael Hartl.

All source code in the Ruby on Rails Tutorial is available jointly under the MIT License and the Beerware License.

Copyright © 2014-2017 Michael Hartl

sample_apps's People

Contributors

himajin315 avatar nashirox avatar paveg avatar sho-h avatar tunepolo avatar yasulab avatar yuppymam avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.