Skip to content

Commit

Permalink
Add basic documentation.
Browse files Browse the repository at this point in the history
  • Loading branch information
ioquatix committed Apr 24, 2024
1 parent 8dd00c0 commit 769aff3
Show file tree
Hide file tree
Showing 4 changed files with 34 additions and 20 deletions.
29 changes: 29 additions & 0 deletions guides/getting-started/readme.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Getting Started

This guide will show you how to use the `rakula` gem to create a simple static website.

## Installation

Add the gem to your project:

~~~ bash
$ bundle add io-event
~~~

and make sure `wget` is also installed, using your system package manager.

## Usage

### Rack Applications

In the root directory, simply run `rackula`. It will generate a static site in `static`. For more details about how to change the default behavior, run `rackula --help`.

### Rails Applications

Add a `config.ru` file to your rails app and follow the above instructions.

``` ruby
# config.ru for rails app
require_relative 'config/environment'
run Rails.application
```
2 changes: 2 additions & 0 deletions guides/links.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
getting-started:
order: 1
1 change: 1 addition & 0 deletions rackula.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Gem::Specification.new do |spec|
spec.homepage = "https://github.com/socketry/rackula"

spec.metadata = {
"documentation_uri" => "https://socketry.github.io/rackula/",
"source_code_uri" => "https://github.com/socketry/rackula.git",
}

Expand Down
22 changes: 2 additions & 20 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,29 +4,11 @@ Rackula will immortalize your rackup web app by generating a static copy. It can

[![Development Status](https://github.com/socketry/rackula/workflows/Test/badge.svg)](https://github.com/socketry/rackula/actions?workflow=Test)

## Installation

Install the gem:

$ gem install rackula

Ensure that `wget` is installed and available.

## Usage

### Rack Applications

In the root directory, simply run `rackula`. It will generate a static site in `static`. For more details about how to change the default behavior, run `rackula --help`.

### Rails Applications

Add a `config.ru` file to your rails app and follow the above instructions.
Please see the [project documentation](https://socketry.github.io/rackula/) for more details.

``` ruby
# config.ru for rails app
require_relative 'config/environment'
run Rails.application
```
- [Getting Started](https://socketry.github.io/rackula/guides/getting-started/index) - This guide will show you how to use the `rakula` gem to create a simple static website.

## Contributing

Expand Down

0 comments on commit 769aff3

Please sign in to comment.