Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Open WIN Community
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
open-science
community
Open WIN Community
Commits
9b86e292
Commit
9b86e292
authored
5 years ago
by
Matthew Wang
Browse files
Options
Downloads
Patches
Plain Diff
implements requested branch and edit mode configs
parent
2c949289
No related branches found
No related tags found
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
_config.yml
+4
-2
4 additions, 2 deletions
_config.yml
_layouts/default.html
+9
-2
9 additions, 2 deletions
_layouts/default.html
docs/configuration.md
+8
-4
8 additions, 4 deletions
docs/configuration.md
with
21 additions
and
8 deletions
_config.yml
+
4
−
2
View file @
9b86e292
...
...
@@ -42,9 +42,11 @@ aux_links:
footer_content
:
"
Copyright
©
2017-2019
Patrick
Marsceill.
Distributed
by
an
<a
href=
\"
https://github.com/pmarsceill/just-the-docs/tree/master/LICENSE.txt
\"
>MIT
license.</a>"
# Footer metadata
show_last_edit_time
:
true
last_edit_time_format
:
"
%b
%e
%Y
at
%I:%M
%p"
last_edit_time_format
:
"
%b
%e
%Y
at
%I:%M
%p"
# uses ruby's time format: https://ruby-doc.org/stdlib-2.7.0/libdoc/time/rdoc/Time.html
show_gh_edit_link
:
true
gh_edit_repository
:
"
https://github.com/pmarsceill/just-the-docs"
gh_edit_repository
:
"
https://github.com/pmarsceill/just-the-docs"
# the github URL for your repo
gh_edit_branch
:
"
master"
# switch to the branch that your docs is served from
gh_edit_view_mode
:
"
tree"
# switch to "edit" if you want the user to jump into the editor immediately
edit_link_text
:
"
Edit
this
page
on
GitHub."
# Color scheme currently only supports "dark" or nil (default)
...
...
This diff is collapsed.
Click to expand it.
_layouts/default.html
+
9
−
2
View file @
9b86e292
...
...
@@ -94,9 +94,16 @@ layout: table_wrappers
Page last modified: {{ page.last_modified_date | date: site.last_edit_time_format }}.
</p>
{% endif %}
{% if site.show_gh_edit_link and site.edit_link_text %}
{%
if
site.show_gh_edit_link and
site.edit_link_text and
site.gh_edit_repository and
site.gh_edit_view_mode and
site.gh_edit_branch
%}
<p
class=
"text-small text-grey-dk-000 mb-0"
>
<a
href=
"{{ site.gh_edit_repository }}/
tree/master
/{{ page.path }}"
>
{{ site.edit_link_text }}
</a>
<a
href=
"{{ site.gh_edit_repository }}/
{{site.gh_edit_view_mode}}/{{site.gh_edit_branch}}
/{{ page.path }}"
>
{{ site.edit_link_text }}
</a>
</p>
{% endif %}
{% if site.footer_content != nil %}
...
...
This diff is collapsed.
Click to expand it.
docs/configuration.md
+
8
−
4
View file @
9b86e292
...
...
@@ -67,15 +67,19 @@ heading_anchors: true
footer_content
:
"
Copyright
©
2017-2019
Patrick
Marsceill.
Distributed
by
an
<a
href=
\"
https://github.com/pmarsceill/just-the-docs/tree/master/LICENSE.txt
\"
>MIT
license.</a>"
# Footer metadata
show_last_edit_time
:
true
last_edit_time_format
:
"
%b
%e
%Y
at
%I:%M
%p"
last_edit_time_format
:
"
%b
%e
%Y
at
%I:%M
%p"
# uses ruby's time format
show_gh_edit_link
:
true
gh_edit_repository
:
"
https://github.com/pmarsceill/just-the-docs"
edit_link_text
:
"
Edit
this
page
on
GitHub"
gh_edit_repository
:
"
https://github.com/pmarsceill/just-the-docs"
# the github URL for your repo
gh_edit_branch
:
"
master"
# switch to the branch that your docs is served from
gh_edit_view_mode
:
"
tree"
# switch to "edit" if you want the user to jump into the editor immediately
edit_link_text
:
"
Edit
this
page
on
GitHub."
```
*
the "page last modified" data will only display if a page has a key called
`last_modified_date`
, formatted in some readable date format
*
`last_edit_time_format`
uses Ruby's DateTime formatter; see examples and more information
[
at this link.
](
https://apidock.com/ruby/DateTime/strftime
)
*
`gh_edit_repository`
should be changed to the project's GitHub repository
*
`gh_edit_repository`
is the URL of the project's GitHub repository
*
`gh_edit_branch`
is the branch that the docs site is served from; defaults to
`master`
*
`gh_edit_view_mode`
is
`"tree"`
by default, which brings the user to the github page; switch to
`"edit"`
to bring the user directly into editing mode
## Color scheme
...
...
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