bullet_train 1.0.33 → 1.0.34
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
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: d4c9a9f0c617e540b2662250fdb01b43fc9da840b28ed162eb4b5557d6e2bd62
|
|
4
|
+
data.tar.gz: 4872a7ed05c26b1ab49a40da4a37015b29ea3ab9ebe5167ac155585dfd561892
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 80e1486b06aca6ed9611bff3423245e3501e58273a5ff0c239368c43dbb2ed550f6e04eba0a9e4be53c0797c9764e0232aaab33e078b46f7c7c299f2e3165313
|
|
7
|
+
data.tar.gz: 3897617f86d2745ca12c4fd59e5e59d2b41faae54316895d0eea7c30224ed8e9dd1fb36e35e2469751b5c22c6e886c3cf6ecbcd5c0a53a553655bb30f13cb710
|
|
@@ -2,7 +2,9 @@ module DocumentationSupport
|
|
|
2
2
|
extend ActiveSupport::Concern
|
|
3
3
|
|
|
4
4
|
def docs
|
|
5
|
-
|
|
5
|
+
target = params[:page].presence || "index"
|
|
6
|
+
files = `find -L tmp/gems/*/docs | grep \.md`.lines.map(&:chomp).sort
|
|
7
|
+
@file = files.detect { |file| file.include?(target) }
|
|
6
8
|
render :docs, layout: "docs"
|
|
7
9
|
end
|
|
8
10
|
end
|
|
@@ -5,20 +5,20 @@
|
|
|
5
5
|
<%
|
|
6
6
|
# we're going to use the
|
|
7
7
|
body = Nokogiri::HTML(@body)
|
|
8
|
-
title = body.css('h1').first.text.presence || t('
|
|
8
|
+
title = body.css('h1').first.text.presence || t('bullet_train.tagline')
|
|
9
9
|
first_paragraph = body.css('p').first
|
|
10
10
|
preceding_heading = first_paragraph&.xpath("preceding-sibling::h2")
|
|
11
|
-
description = [preceding_heading&.text, first_paragraph&.text].select(&:present?).join(" — ") || t('
|
|
11
|
+
description = [preceding_heading&.text, first_paragraph&.text].select(&:present?).join(" — ") || t('bullet_train.description')
|
|
12
12
|
image_url = "https://avatars.githubusercontent.com/u/5976880?s=280&v=4"
|
|
13
13
|
site_name = "Bullet Train Developer Documentation"
|
|
14
14
|
%>
|
|
15
15
|
|
|
16
16
|
<% content_for :title do %>
|
|
17
|
-
<title><%= [site_name, title, t('
|
|
17
|
+
<title><%= [site_name, title, t('bullet_train.tagline')].select(&:present?).uniq.first(2).reverse.join(' — ') %></title>
|
|
18
18
|
<% end %>
|
|
19
19
|
|
|
20
20
|
<%= render 'themes/light/layouts/head' %>
|
|
21
|
-
<meta content="<%= t('
|
|
21
|
+
<meta content="<%= t('bullet_train.keywords') %>" name="keywords" />
|
|
22
22
|
<meta content="<%= description.truncate(200) %>" name="description" />
|
|
23
23
|
<meta name="twitter:image:src" content="<%= image_url %>" />
|
|
24
24
|
<meta name="twitter:site" content="@bullettrainco" />
|
|
@@ -1 +1 @@
|
|
|
1
|
-
<%= @body = markdown(File.read(Rails.root.to_s + "
|
|
1
|
+
<%= @body = markdown(File.read(Rails.root.to_s + "/#{@file}").gsub('.md)', ')')) %>
|
data/lib/bullet_train/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: bullet_train
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.0.
|
|
4
|
+
version: 1.0.34
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Andrew Culver
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2022-03-
|
|
11
|
+
date: 2022-03-22 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rails
|