Skip to content

Commit

Permalink
[CI/dep] Update docsy + submodule workaround (#3926)
Browse files Browse the repository at this point in the history
  • Loading branch information
chalin authored Feb 1, 2024
1 parent 12b42d4 commit a98e030
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 59 deletions.
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[submodule "themes/docsy"]
path = themes/docsy
url = https://github.com/cncf/docsy.git
docsy-pin = v0.8.0-17-g91efe35
docsy-pin = v0.8.0-21-g435b2e0
[submodule "content-modules/opentelemetry-specification"]
path = content-modules/opentelemetry-specification
url = https://github.com/open-telemetry/opentelemetry-specification.git
Expand Down
55 changes: 0 additions & 55 deletions layouts/partials/page-meta-links.html

This file was deleted.

13 changes: 11 additions & 2 deletions scripts/content-modules/adjust-pages.pl
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
my $semconvSpecRepoUrl = 'https://github.com/open-telemetry/semantic-conventions';
my $semConvRef = "$otelSpecRepoUrl/blob/main/semantic_conventions/README.md";
my $specBasePath = '/docs/specs';
my $path_base_for_github_subdir = "content/en$specBasePath";
my %versions = qw(
spec: 1.29.0
otlp: 1.1.0
Expand Down Expand Up @@ -52,12 +51,22 @@ ()
# TODO: add to front matter of OTel spec file and drop next line:
$linkTitle = 'Design Goals' if $title eq 'Design Goals for OpenTelemetry Wire Protocol';

# TODO: remove once all submodules have been updated in the context of https://github.com/open-telemetry/opentelemetry.io/issues/3922
$frontMatterFromFile =~ s|: content/en/docs/specs/otel/|: tmp/otel/specification|g;
$frontMatterFromFile =~ s|: content/en/docs/specs/opamp/|: tmp/opamp/|g;
$frontMatterFromFile =~ s|: content/en/docs/specs/semconv/|: tmp/semconv/docs/|g;
$frontMatterFromFile =~ s|path_base_for_github_subdir:\n from: content/en/docs/specs/otlp/_index.md\n to: specification.md\n||;
$frontMatterFromFile =~ s|github_subdir: docs\n path_base_for_github_subdir: content/en/docs/specs/otlp/|path_base_for_github_subdir: tmp/otlp/|g;

$frontMatterFromFile =~ s|github_subdir: ''\npath_base_for_github_subdir:\n from: content/en/community/mission\\.md\n to: mission-vision-values.md|path_base_for_github_subdir: tmp/community|;
$frontMatterFromFile =~ s|github_subdir: ''\npath_base_for_github_subdir: content/en/community/|path_base_for_github_subdir: tmp/community|;

# printf STDOUT "> $title -> $linkTitle\n";
print "linkTitle: $linkTitle\n" if $linkTitle and $frontMatterFromFile !~ /linkTitle: /;
print "$frontMatterFromFile" if $frontMatterFromFile;
if ($ARGV =~ /otel\/specification\/(.*?)_index.md$/) {
print "path_base_for_github_subdir:\n";
print " from: $path_base_for_github_subdir/otel/$1_index.md\n";
print " from: tmp/otel/specification/$1_index.md\n";
print " to: $1README.md\n";
}
print "---\n";
Expand Down
2 changes: 1 addition & 1 deletion themes/docsy

0 comments on commit a98e030

Please sign in to comment.