parklife 0.8.0 → 0.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/examples.yml +0 -15
- data/.github/workflows/tests.yml +1 -28
- data/CHANGELOG.md +4 -0
- data/Gemfile +0 -1
- data/README.md +2 -2
- data/lib/parklife/cli.rb +1 -1
- data/lib/parklife/templates/Parkfile.erb +1 -1
- data/lib/parklife/version.rb +1 -1
- metadata +2 -7
- data/Appraisals +0 -13
- data/gemfiles/sinatra_3.x.gemfile +0 -12
- data/gemfiles/sinatra_4.0.gemfile +0 -12
- data/gemfiles/sinatra_4.1.gemfile +0 -12
- data/lib/parklife/sinatra.rb +0 -19
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: b76fbfd9c4d1a56c6b2498e1e5470e5ac43bd06fc68ef5e944ed2f2c5b0ab81c
|
|
4
|
+
data.tar.gz: '0808d1e25b27429f521002f7e28d41c254dcee31e2ea4b76a639f1bbd61d15b0'
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 950ab97e849c11e69181093a0dd110f51fcafbc22ab869dbff07dd1ce79f69cb78dfbd9ffe5311b0b1d34fbd770f531042d5a646f349ab387b00b44fe6c0cc97
|
|
7
|
+
data.tar.gz: 23d920c50159706d18f20c958abb98f59e320b841a7ab00cde022c57ef8fb9b4b9e14486965ae55f538d0820c378f4c0b41c3bc30a37d8eee5250101ab5cee5a
|
|
@@ -32,18 +32,3 @@ jobs:
|
|
|
32
32
|
working-directory: examples/roda
|
|
33
33
|
- run: test -f build/index.html
|
|
34
34
|
working-directory: examples/roda
|
|
35
|
-
|
|
36
|
-
sinatra:
|
|
37
|
-
runs-on: ubuntu-latest
|
|
38
|
-
name: Sinatra example
|
|
39
|
-
steps:
|
|
40
|
-
- uses: actions/checkout@v3
|
|
41
|
-
- uses: ruby/setup-ruby@v1
|
|
42
|
-
with:
|
|
43
|
-
bundler-cache: true
|
|
44
|
-
ruby-version: '3.4'
|
|
45
|
-
working-directory: examples/sinatra
|
|
46
|
-
- run: bin/static-build
|
|
47
|
-
working-directory: examples/sinatra
|
|
48
|
-
- run: test -f build/index.html
|
|
49
|
-
working-directory: examples/sinatra
|
data/.github/workflows/tests.yml
CHANGED
|
@@ -22,7 +22,7 @@ jobs:
|
|
|
22
22
|
with:
|
|
23
23
|
bundler-cache: true
|
|
24
24
|
ruby-version: ${{ matrix.ruby }}
|
|
25
|
-
- run: bundle exec rspec
|
|
25
|
+
- run: bundle exec rspec
|
|
26
26
|
|
|
27
27
|
rubocop:
|
|
28
28
|
runs-on: ubuntu-latest
|
|
@@ -34,30 +34,3 @@ jobs:
|
|
|
34
34
|
bundler-cache: true
|
|
35
35
|
ruby-version: '3.2'
|
|
36
36
|
- run: bundle exec rubocop
|
|
37
|
-
|
|
38
|
-
sinatra:
|
|
39
|
-
runs-on: ubuntu-latest
|
|
40
|
-
strategy:
|
|
41
|
-
fail-fast: false
|
|
42
|
-
matrix:
|
|
43
|
-
ruby:
|
|
44
|
-
- '2.7'
|
|
45
|
-
- '3.0'
|
|
46
|
-
- '3.1'
|
|
47
|
-
- '3.2'
|
|
48
|
-
- '3.3'
|
|
49
|
-
- '3.4'
|
|
50
|
-
sinatra:
|
|
51
|
-
- '3.x'
|
|
52
|
-
- '4.0'
|
|
53
|
-
- '4.1'
|
|
54
|
-
env:
|
|
55
|
-
BUNDLE_GEMFILE: gemfiles/sinatra_${{ matrix.sinatra }}.gemfile
|
|
56
|
-
name: Ruby ${{ matrix.ruby }} / Sinatra ${{ matrix.sinatra }}
|
|
57
|
-
steps:
|
|
58
|
-
- uses: actions/checkout@v4
|
|
59
|
-
- uses: ruby/setup-ruby@v1
|
|
60
|
-
with:
|
|
61
|
-
bundler-cache: true
|
|
62
|
-
ruby-version: ${{ matrix.ruby }}
|
|
63
|
-
- run: bundle exec rspec --pattern "spec/**/*sinatra*"
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
## Unreleased
|
|
2
2
|
|
|
3
|
+
## Version 0.8.1 - 2025-12-21
|
|
4
|
+
|
|
5
|
+
- Move out-of-the-box Sinatra integration into a separate [`parklife-sinatra`](https://github.com/benpickles/parklife-sinatra) gem. <https://github.com/benpickles/parklife/pull/133>
|
|
6
|
+
|
|
3
7
|
## Version 0.8.0 - 2025-09-08
|
|
4
8
|
|
|
5
9
|
Note that **Parklife's Rails integration has been moved into a separate gem** with some additional functionality, [see the `parklife-rails` repo for more information](https://github.com/benpickles/parklife-rails).
|
data/Gemfile
CHANGED
data/README.md
CHANGED
|
@@ -23,7 +23,7 @@ $ bundle exec parklife init
|
|
|
23
23
|
> [!NOTE]
|
|
24
24
|
> See the [`parklife-rails` repository](https://github.com/benpickles/parklife-rails) for how to use Parklife with Rails.
|
|
25
25
|
|
|
26
|
-
Parklife is configured with a file called `Parkfile` in the root of your project, here's an example `Parkfile` for an imaginary
|
|
26
|
+
Parklife is configured with a file called `Parkfile` in the root of your project, here's an example `Parkfile` for an imaginary Rack app:
|
|
27
27
|
|
|
28
28
|
```ruby
|
|
29
29
|
# Assuming your Rack app lives in ./app.rb:
|
|
@@ -78,7 +78,7 @@ Parklife doesn't know about assets (images, CSS, etc) so you likely also need to
|
|
|
78
78
|
|
|
79
79
|
## More examples
|
|
80
80
|
|
|
81
|
-
Take a look at the [`parklife-rails` example app](https://github.com/benpickles/parklife-rails/tree/main/example-app),
|
|
81
|
+
Take a look at the [`parklife-rails` example app](https://github.com/benpickles/parklife-rails/tree/main/example-app), the [`parklife-sinatra` example app](https://github.com/benpickles/parklife-sinatra/tree/main/example-app), and the [Rack](examples/rack/Parkfile) example in this repository.
|
|
82
82
|
|
|
83
83
|
## Configuration
|
|
84
84
|
|
data/lib/parklife/cli.rb
CHANGED
|
@@ -26,7 +26,7 @@ module Parklife
|
|
|
26
26
|
['nested_index', application.config.nested_index],
|
|
27
27
|
['on_404', application.config.on_404.inspect],
|
|
28
28
|
['parklife-rails', defined?(::Parklife::Rails) ? 'enabled' : '-'],
|
|
29
|
-
['parklife
|
|
29
|
+
['parklife-sinatra', defined?(::Parklife::Sinatra) ? 'enabled' : '-'],
|
|
30
30
|
['reporter', reporter == $stdout ? '$stdout' : reporter],
|
|
31
31
|
])
|
|
32
32
|
end
|
data/lib/parklife/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: parklife
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.8.
|
|
4
|
+
version: 0.8.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ben Pickles
|
|
@@ -64,7 +64,6 @@ files:
|
|
|
64
64
|
- ".gitignore"
|
|
65
65
|
- ".rspec"
|
|
66
66
|
- ".rubocop.yml"
|
|
67
|
-
- Appraisals
|
|
68
67
|
- CHANGELOG.md
|
|
69
68
|
- CODE_OF_CONDUCT.md
|
|
70
69
|
- Gemfile
|
|
@@ -74,9 +73,6 @@ files:
|
|
|
74
73
|
- bin/console
|
|
75
74
|
- bin/setup
|
|
76
75
|
- exe/parklife
|
|
77
|
-
- gemfiles/sinatra_3.x.gemfile
|
|
78
|
-
- gemfiles/sinatra_4.0.gemfile
|
|
79
|
-
- gemfiles/sinatra_4.1.gemfile
|
|
80
76
|
- lib/parklife.rb
|
|
81
77
|
- lib/parklife/application.rb
|
|
82
78
|
- lib/parklife/browser.rb
|
|
@@ -86,7 +82,6 @@ files:
|
|
|
86
82
|
- lib/parklife/errors.rb
|
|
87
83
|
- lib/parklife/route.rb
|
|
88
84
|
- lib/parklife/route_set.rb
|
|
89
|
-
- lib/parklife/sinatra.rb
|
|
90
85
|
- lib/parklife/templates/Parkfile.erb
|
|
91
86
|
- lib/parklife/templates/github_pages.yml
|
|
92
87
|
- lib/parklife/templates/static_build.erb
|
|
@@ -115,7 +110,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
115
110
|
- !ruby/object:Gem::Version
|
|
116
111
|
version: '0'
|
|
117
112
|
requirements: []
|
|
118
|
-
rubygems_version: 3.
|
|
113
|
+
rubygems_version: 3.6.9
|
|
119
114
|
specification_version: 4
|
|
120
115
|
summary: Convert a Rack app into a static HTML site.
|
|
121
116
|
test_files: []
|
data/Appraisals
DELETED
data/lib/parklife/sinatra.rb
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
# frozen_string_literal: true
|
|
2
|
-
|
|
3
|
-
require 'sinatra/base'
|
|
4
|
-
|
|
5
|
-
module Parklife
|
|
6
|
-
module Sinatra
|
|
7
|
-
def self.registered(app)
|
|
8
|
-
# Disable Rack::Protection::HostAuthorization middleware so that fetching
|
|
9
|
-
# a page with Parklife works in development. It's safe to do here because
|
|
10
|
-
# it will only be executed when this file is explicitly required in a
|
|
11
|
-
# Parkfile and not in general when the app is running in a web server.
|
|
12
|
-
if app.settings.respond_to?(:host_authorization)
|
|
13
|
-
app.set(:host_authorization, permitted_hosts: [])
|
|
14
|
-
end
|
|
15
|
-
end
|
|
16
|
-
end
|
|
17
|
-
end
|
|
18
|
-
|
|
19
|
-
Sinatra.register Parklife::Sinatra
|