Fix those stupid little errors
This commit is contained in:
parent
20ee4a1e5b
commit
7a8171a1cf
3 changed files with 9 additions and 5 deletions
|
@ -2,8 +2,10 @@
|
||||||
{{- $img := .Page.Resources.GetMatch .Destination -}}
|
{{- $img := .Page.Resources.GetMatch .Destination -}}
|
||||||
|
|
||||||
{{- if and (not $img) .Page.File -}}
|
{{- if and (not $img) .Page.File -}}
|
||||||
{{ $path := path.Join .Page.File.Dir .Destination }}
|
{{ with .Page.File }}
|
||||||
|
{{ $path := path.Join .Dir .Destination }}
|
||||||
{{- $img = resources.Get $path -}}
|
{{- $img = resources.Get $path -}}
|
||||||
|
{{ end }}
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
||||||
{{- if and (not $img) .Page.File -}}
|
{{- if and (not $img) .Page.File -}}
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
|
|
||||||
<table class="w-full table-auto mt-4">
|
<table class="w-full table-auto mt-4">
|
||||||
<tr>
|
<tr>
|
||||||
{{ if in .File.Dir "software" }}
|
{{ if and (.File) (in .File.Dir "software") }}
|
||||||
<th>Name</th>
|
<th>Name</th>
|
||||||
<th>Description</th>
|
<th>Description</th>
|
||||||
<th>Year Created</th>
|
<th>Year Created</th>
|
||||||
|
@ -24,7 +24,7 @@
|
||||||
</td>
|
</td>
|
||||||
|
|
||||||
<td class="border-t">
|
<td class="border-t">
|
||||||
{{ if in .File.Dir "software" }}
|
{{ if and (.File) (in .File.Dir "software") }}
|
||||||
<time datetime='{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}'>{{ .Date.Format " 2006"}}</time>
|
<time datetime='{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}'>{{ .Date.Format " 2006"}}</time>
|
||||||
{{ else }}
|
{{ else }}
|
||||||
<time datetime='{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}'>{{ .Date.Format "Jan 2, 2006"}}</time>
|
<time datetime='{{ .Date.Format "2006-01-02T15:04:05Z07:00" }}'>{{ .Date.Format "Jan 2, 2006"}}</time>
|
||||||
|
|
|
@ -23,7 +23,9 @@
|
||||||
|
|
||||||
<a href="/imprint">Imprint</a>
|
<a href="/imprint">Imprint</a>
|
||||||
|
|
||||||
<a href="https://git.sr.ht/~redstrate/redstrate.com/tree/master/item/content/{{ .File.Path }}?view-source">Source</a>
|
{{ with .File }}
|
||||||
|
<a href="https://git.sr.ht/~redstrate/redstrate.com/tree/master/item/content/{{ .Path }}?view-source">Source</a>
|
||||||
|
{{ end }}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<hr>
|
<hr>
|
||||||
|
|
Loading…
Add table
Reference in a new issue