Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-docs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2022-12-08 15:46:14 +0300
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2022-12-08 15:46:14 +0300
commitae4f7f4129e4593dc829614b7ea19330e2937c5c (patch)
treea18be881efa785402012b3063b11c3b93a7c6b03
parentb38ed6773a9ec2bcf85e660848bbf3150ccf1602 (diff)
Fix how we find blueprints to generate index page for
-rw-r--r--lib/helpers/blueprints.rb10
1 files changed, 8 insertions, 2 deletions
diff --git a/lib/helpers/blueprints.rb b/lib/helpers/blueprints.rb
index 2e889732..2e12cc0b 100644
--- a/lib/helpers/blueprints.rb
+++ b/lib/helpers/blueprints.rb
@@ -2,8 +2,14 @@
module Nanoc::Helpers
module Blueprints
+ BLUEPRINTS_PATH = '/ee/architecture/blueprints/*/index.md'.freeze
+
def all_blueprints
- @items.find_all('/ee/architecture/blueprints/**/*.md').sort_by { |i| blueprint_creation_date(i) }.reverse
+ blueprints = @items.find_all(BLUEPRINTS_PATH).sort_by do |i|
+ blueprint_creation_date(i)
+ end
+
+ blueprints.reverse
end
def author_link(author)
@@ -18,7 +24,7 @@ module Nanoc::Helpers
# TODO: this is generic, should live elsewhere
def gl_label(label)
return if label.nil?
-
+
scope, text = label.tr('~', '').split('::')
is_scoped = !text.nil?