FAQ
| This is a
LIVE
service |
Changelog
Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
DevOps Division Guidebook
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Information Services
DevOps
General Documentation
DevOps Division Guidebook
Commits
2745ddf6
Commit
2745ddf6
authored
3 weeks ago
by
Nick Brown
Browse files
Options
Downloads
Patches
Plain Diff
chore: Debugging behaviour in Gitlab CI
parent
dbb2fb95
No related branches found
Branches containing commit
No related tags found
1 merge request
!453
feat: Knowledge base enhancements (diataxis)
Pipeline
#714044
passed
3 weeks ago
Stage: test
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
hooks/site_urls.py
+6
-4
6 additions, 4 deletions
hooks/site_urls.py
with
6 additions
and
4 deletions
hooks/site_urls.py
+
6
−
4
View file @
2745ddf6
...
...
@@ -54,15 +54,17 @@ def on_page_content(html, page, config, files):
if
not
path
.
endswith
(
"
/
"
):
path
+=
"
/
"
if
not
use_directory_urls
:
path
+=
"
index.html
"
def
_replace
(
match
):
def
_replace
(
match
,
use_directory_urls
:
bool
=
use_directory_urls
):
param
=
match
.
group
(
1
)
url
=
match
.
group
(
2
)
if
url
.
startswith
(
"
/
"
):
url
=
url
[
1
:]
if
not
use_directory_urls
:
if
not
url
.
endswith
(
"
/
"
):
url
+=
"
/
"
url
+=
"
index.html
"
log
.
info
(
f
"
REPLACING site:
{
match
.
group
(
2
)
}
with
{
path
}{
url
}
"
)
return
f
'
{
param
}
=
"
{
path
}{
url
}
"'
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment