Merge branch 'hugo' of https://github.com/jackyzha0/quartz into hugo
This commit is contained in:
commit
b78c02c6f3
2
.github/workflows/deploy.yaml
vendored
2
.github/workflows/deploy.yaml
vendored
@ -10,6 +10,8 @@ jobs:
|
|||||||
runs-on: ubuntu-18.04
|
runs-on: ubuntu-18.04
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
|
||||||
|
|
||||||
- name: Build Link Index
|
- name: Build Link Index
|
||||||
uses: jackyzha0/hugo-obsidian@v2.12
|
uses: jackyzha0/hugo-obsidian@v2.12
|
||||||
|
@ -28,3 +28,6 @@ enableGitInfo = true
|
|||||||
lineNumbersInTable = true
|
lineNumbersInTable = true
|
||||||
style = "dracula"
|
style = "dracula"
|
||||||
tabWidth = 4
|
tabWidth = 4
|
||||||
|
[frontmatter]
|
||||||
|
lastmod = ["lastmod", ":git", "date", "publishDate"]
|
||||||
|
publishDate = ["publishDate", "date"]
|
@ -7,7 +7,7 @@
|
|||||||
{{$spacedurl := replace $trimmed "%20" " " }}
|
{{$spacedurl := replace $trimmed "%20" " " }}
|
||||||
{{$fixedUrl := (cond (hasPrefix $spacedurl "/") $spacedurl (print "/" $spacedurl)) | urlize}}
|
{{$fixedUrl := (cond (hasPrefix $spacedurl "/") $spacedurl (print "/" $spacedurl)) | urlize}}
|
||||||
{{$nonexistent := eq (.Page.GetPage $spacedurl).RelPermalink ""}}
|
{{$nonexistent := eq (.Page.GetPage $spacedurl).RelPermalink ""}}
|
||||||
{{$rooted := default $spacedurl (strings.TrimRight "/" (.Page.GetPage $spacedurl).RelPermalink) }}
|
{{$rooted := default $spacedurl ((.Page.GetPage $spacedurl).RelPermalink) }}
|
||||||
<a
|
<a
|
||||||
{{if not $nonexistent}}href="{{$rooted}}"{{end}}
|
{{if not $nonexistent}}href="{{$rooted}}"{{end}}
|
||||||
rel="noopener" class="internal-link{{if $nonexistent}} broken{{end}}"
|
rel="noopener" class="internal-link{{if $nonexistent}} broken{{end}}"
|
||||||
|
Loading…
Reference in New Issue
Block a user