Skip to content

Commit 662fc3a

Browse files
toshimaruclaudeCopilot
authored
docs: Add setup section to README (railsdoc#185)
* Ignore .env * Create .env.sample * docs: Add Docker usage instructions to README Add section explaining how to run the project with Docker Compose, including examples for different Ruby versions and development server. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]> * docs: Setup/Build/Serve * docs: Simplify docker document * fix: Fix file name Co-authored-by: Copilot <[email protected]> --------- Co-authored-by: Claude <[email protected]> Co-authored-by: Copilot <[email protected]>
1 parent cb803c3 commit 662fc3a

File tree

3 files changed

+44
-3
lines changed

3 files changed

+44
-3
lines changed

.env.sample

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
RUBY_VERSION=2.7

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
_site
22
.sass-cache
3+
.env

README.md

Lines changed: 42 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
# [railsdoc.github.io](https://railsdoc.github.io/)
1+
# [railsdoc.github.io](https://railsdoc.github.io/)
22

33
[![CI](https://github.com/railsdoc/railsdoc.github.io/actions/workflows/ci.yml/badge.svg)](https://github.com/railsdoc/railsdoc.github.io/actions/workflows/ci.yml)
44
[![Deploy](https://github.com/railsdoc/railsdoc.github.io/actions/workflows/deploy.yml/badge.svg)](https://github.com/railsdoc/railsdoc.github.io/actions/workflows/deploy.yml)
55
[![Netlify Status](https://api.netlify.com/api/v1/badges/c964029a-6d5a-4f3a-95e9-d35830a2fe83/deploy-status)](https://app.netlify.com/sites/railsdoc-preview/deploys)
66

7-
railsdoc.github.io is yet another Rails API documentation website.
7+
[railsdoc.github.io](https://railsdoc.github.io/) is yet another Rails API documentation website.
88

99
## Project Goal
1010

@@ -24,6 +24,45 @@ There are some enhancements in addition to SEO.
2424
- [ ] Comment System
2525
- [ ] etc. (see. https://github.com/railsdoc/railsdoc.github.io/issues)
2626

27-
## Feature Request
27+
## Setup
28+
29+
```console
30+
$ bundle install
31+
```
32+
33+
## Build docs
34+
35+
For the latest Rails version:
36+
37+
```console
38+
$ rake build
39+
```
40+
41+
This command generates Rails docs with `default_rails_version` defined in `_config.yml`.
42+
43+
For specific Rails versions:
44+
45+
```console
46+
$ rake build_multi[5.2,6.0,6.1]
47+
```
48+
49+
### Using docker for the older Rails build
50+
51+
Set `RUBY_VERSION` in `.env` file and run `docker compose`.
52+
53+
```console
54+
$ cp .env.sample .env
55+
$ docker compose run app bash -c 'rake build_multi[5.2]'
56+
```
57+
58+
## Serve docs
59+
60+
Serve html under `src` directory.
61+
62+
```console
63+
$ bundle exec jekyll server
64+
```
65+
66+
## Feature Request
2867

2968
Please create an [issue](https://github.com/railsdoc/railsdoc.github.io/issues).

0 commit comments

Comments
 (0)