Loading config/_default/config.yaml +1 −0 Original line number Diff line number Diff line Loading @@ -5,6 +5,7 @@ title: The GitLab Handbook params: branch: main project: https://gitlab.com/gitlab-com/content-sites/handbook repoid: 40085411 plantuml: enable: true # svg: true Loading content/handbook/about/changelog.md 0 → 100644 +7 −0 Original line number Diff line number Diff line --- title: Handbook Changelog description: The last 100 Merge Requests to the Handbook type: docs --- {{< mr-list >}} layouts/shortcodes/mr-list.html +6 −2 Original line number Diff line number Diff line {{ $data := getJSON "https://gitlab.com/api/v4/projects/42817607/merge_requests?" "&state=merged" "&per_page=100" }} {{ $apiURL := printf "https://gitlab.com/api/v4/projects/%d/merge_requests?state=merged&per_page=100" site.Params.repoid}} {{- $options := dict -}} {{- with site.Params.GITLAB_API_KEY -}} {{- $options = merge $options (dict "Authorization" (printf "Bearer %s" .)) -}} {{- end -}} {{ $data := getJSON $apiURL $options }} {{ $.Scratch.Set "lastdate" "2000-01-01T00:00:00.000Z"}} Loading @@ -20,4 +25,3 @@ <li><a href="https://gitlab.com/gitlab-com/content-sites/handbook/merge_requests/{{ .iid }}">!{{ .iid }}</a> - {{ .title }}</li> {{ end }} </table> Loading
config/_default/config.yaml +1 −0 Original line number Diff line number Diff line Loading @@ -5,6 +5,7 @@ title: The GitLab Handbook params: branch: main project: https://gitlab.com/gitlab-com/content-sites/handbook repoid: 40085411 plantuml: enable: true # svg: true Loading
content/handbook/about/changelog.md 0 → 100644 +7 −0 Original line number Diff line number Diff line --- title: Handbook Changelog description: The last 100 Merge Requests to the Handbook type: docs --- {{< mr-list >}}
layouts/shortcodes/mr-list.html +6 −2 Original line number Diff line number Diff line {{ $data := getJSON "https://gitlab.com/api/v4/projects/42817607/merge_requests?" "&state=merged" "&per_page=100" }} {{ $apiURL := printf "https://gitlab.com/api/v4/projects/%d/merge_requests?state=merged&per_page=100" site.Params.repoid}} {{- $options := dict -}} {{- with site.Params.GITLAB_API_KEY -}} {{- $options = merge $options (dict "Authorization" (printf "Bearer %s" .)) -}} {{- end -}} {{ $data := getJSON $apiURL $options }} {{ $.Scratch.Set "lastdate" "2000-01-01T00:00:00.000Z"}} Loading @@ -20,4 +25,3 @@ <li><a href="https://gitlab.com/gitlab-com/content-sites/handbook/merge_requests/{{ .iid }}">!{{ .iid }}</a> - {{ .title }}</li> {{ end }} </table>