From nobody Mon Feb 28 19:48:58 2022 X-Original-To: dev-commits-doc-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 7306819E0532 for ; Mon, 28 Feb 2022 19:48:59 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4K6rY71KBHz4dby; Mon, 28 Feb 2022 19:48:59 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1646077739; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZgS8k+9FJ56332v7JCSgeX7ocsXLUILrv3ZEDyK1H30=; b=C7uriQIfMbSArap16BvkTWKZlSF4FnCAwDD8KScjw+U6AC37Xxfg7CcQ5/2Si6b+f/p78k 8uuW6CL4U2CMl1F/CBZ4CHsBd5cUWfzcZusjCbT0zAiPJmYOPdUbsD1gV6KV6M+KMQGRpw Wwi+w3s1eE0B4ycfG1FFNUghhPLBe2pGBPrxXn7ZgTx1g5n5dxyaUJfcE4FIzMsmdn2exh wduWIcHWaU4XP2tE0LEXLeysn4yFiuNiNke/cGGShxXY4hrAR3giur9j9R2Safa6aW3h3i JQf1Xl3LlijQKpZMceYv0VN+fbPu4DYw4ZUIllgJ3I4nPxPZnFS34wzsBoRv4A== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id E6283215C5; Mon, 28 Feb 2022 19:48:58 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 21SJmwWT021567; Mon, 28 Feb 2022 19:48:58 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 21SJmwdX021566; Mon, 28 Feb 2022 19:48:58 GMT (envelope-from git) Date: Mon, 28 Feb 2022 19:48:58 GMT Message-Id: <202202281948.21SJmwdX021566@gitrepo.freebsd.org> To: doc-committers@FreeBSD.org, dev-commits-doc-all@FreeBSD.org From: Sergio Carlavilla Delgado Subject: git: df67e600e8 - main - Activate download pdf links for articles and books List-Id: Commit messages for all branches of the doc repository List-Archive: https://lists.freebsd.org/archives/dev-commits-doc-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-doc-all@freebsd.org X-BeenThere: dev-commits-doc-all@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: carlavilla X-Git-Repository: doc X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: df67e600e820b9f691bc94fc7c6c60fce8205405 Auto-Submitted: auto-generated ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1646077739; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=ZgS8k+9FJ56332v7JCSgeX7ocsXLUILrv3ZEDyK1H30=; b=wE/agL/pBEQfVjZwJWn3Ea8zGdR8RvPtjoW6VoCwvB1No2xLEK/YZ9pIKsXiSIYndQ5x7c Zy6qYKf/1uAgAhbD/yP8wvkKFcYZpj1Xk4uB/s2EE8aEjtgsOSG28Huo5dwMiZes4v/bPl xvr0mUcgQ3Lvbrv5xQdmTMad1jPDn6w5ccSDcp1uu2fz+40qO0v+v0PcVAhYqPBayV76hK 4t/1A0DK22gsOMYpXKvja1S5f2HGZ4wpx0rk3BnMsnaExlQvT575I19OiShI1Jv70jyNWh hAJxxwWPGxZj4YmluoIO0Ile5+Dw6yzqojR/LbeJb468xhLtbXwRg59uTcbluA== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1646077739; a=rsa-sha256; cv=none; b=RQW3hVCQByOwWmYwpJdz66kY2YofWao3aOcyma/f0JbCXa4C8xmqApqDmj6uxUl3veb1Op 4x+dBx0fpByiU9tmzdwfF8wJyhjlg9HPN86tDfkwRyhoygPsyQItYXfNkCp3FrOxL+YUzT VYLUD2HcW68jtTcCVKy21zpQZOw11Z9d+uFBkro1YRUs3y9+VeqC4v/8JJmfy3uVQHF3S1 BahK4/uFYQyL4AaCRspMfMikn1X8YkLk2GqxSZuwijkxXh7tRFJ7OfNHtiJvHkrhoZX32t w15RpvoRABIniQy1EGwlKrLS1j8GHDCWCTISAoNbBnB7cnQnxKf50I0tH8Fc8A== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by carlavilla: URL: https://cgit.FreeBSD.org/doc/commit/?id=df67e600e820b9f691bc94fc7c6c60fce8205405 commit df67e600e820b9f691bc94fc7c6c60fce8205405 Author: Sergio Carlavilla Delgado AuthorDate: 2022-02-28 19:48:25 +0000 Commit: Sergio Carlavilla Delgado CommitDate: 2022-02-28 19:48:25 +0000 Activate download pdf links for articles and books --- documentation/config/_default/config.toml | 1 + documentation/themes/beastie/layouts/articles/list.html | 7 +++++-- documentation/themes/beastie/layouts/articles/single.html | 7 +++++-- documentation/themes/beastie/layouts/books/list.html | 5 ++++- documentation/themes/beastie/layouts/books/single.html | 5 ++++- 5 files changed, 19 insertions(+), 6 deletions(-) diff --git a/documentation/config/_default/config.toml b/documentation/config/_default/config.toml index 17f8bb41dd..8795386966 100644 --- a/documentation/config/_default/config.toml +++ b/documentation/config/_default/config.toml @@ -18,6 +18,7 @@ googleAnalytics = 'UA-22767463-1' description = "FreeBSD Documentation Portal" isOnline = true editBaseUrl = "https://github.com/freebsd/freebsd-doc/edit/main/documentation/content/" + downloadBaseUrl = "https://download.freebsd.org/doc/" [security] enableInlineShortcodes = false diff --git a/documentation/themes/beastie/layouts/articles/list.html b/documentation/themes/beastie/layouts/articles/list.html index d79f13bb32..8719a9cc87 100644 --- a/documentation/themes/beastie/layouts/articles/list.html +++ b/documentation/themes/beastie/layouts/articles/list.html @@ -43,9 +43,12 @@

{{ i18n "resources" }}

    - + {{ $pathSections := split .Page.File "/" }} + {{ $path := printf "%s/%s/%s_%s.pdf" (index $pathSections 0) (index $pathSections 1) (index $pathSections 1) $.Site.Home.Language }} + {{ $pdfUrl := printf "%s%s/%s" $.Site.Params.downloadBaseUrl $.Site.Home.Language $path }} +
  • {{ i18n "download-pdf" }}
  • {{ $editUrl := printf "%s%s/%s" $.Site.Params.editBaseUrl $.Site.Home.Language .Page.File }} -
  • {{ i18n "edit-page" }}
  • +
  • {{ i18n "edit-page" }}
diff --git a/documentation/themes/beastie/layouts/articles/single.html b/documentation/themes/beastie/layouts/articles/single.html index d79f13bb32..8719a9cc87 100644 --- a/documentation/themes/beastie/layouts/articles/single.html +++ b/documentation/themes/beastie/layouts/articles/single.html @@ -43,9 +43,12 @@

{{ i18n "resources" }}

    - + {{ $pathSections := split .Page.File "/" }} + {{ $path := printf "%s/%s/%s_%s.pdf" (index $pathSections 0) (index $pathSections 1) (index $pathSections 1) $.Site.Home.Language }} + {{ $pdfUrl := printf "%s%s/%s" $.Site.Params.downloadBaseUrl $.Site.Home.Language $path }} +
  • {{ i18n "download-pdf" }}
  • {{ $editUrl := printf "%s%s/%s" $.Site.Params.editBaseUrl $.Site.Home.Language .Page.File }} -
  • {{ i18n "edit-page" }}
  • +
  • {{ i18n "edit-page" }}
diff --git a/documentation/themes/beastie/layouts/books/list.html b/documentation/themes/beastie/layouts/books/list.html index fc99508c90..95f282804d 100644 --- a/documentation/themes/beastie/layouts/books/list.html +++ b/documentation/themes/beastie/layouts/books/list.html @@ -122,7 +122,10 @@

{{ i18n "resources" }}

    - + {{ $pathSections := split .Page.File "/" }} + {{ $path := printf "%s/%s/%s_%s.pdf" (index $pathSections 0) (index $pathSections 1) (index $pathSections 1) $.Site.Home.Language }} + {{ $pdfUrl := printf "%s%s/%s" $.Site.Params.downloadBaseUrl $.Site.Home.Language $path }} +
  • {{ i18n "download-pdf" }}
  • {{ $editUrl := printf "%s%s/%s" $.Site.Params.editBaseUrl $.Site.Home.Language .Page.File }}
  • {{ i18n "edit-page" }}
diff --git a/documentation/themes/beastie/layouts/books/single.html b/documentation/themes/beastie/layouts/books/single.html index fc99508c90..95f282804d 100644 --- a/documentation/themes/beastie/layouts/books/single.html +++ b/documentation/themes/beastie/layouts/books/single.html @@ -122,7 +122,10 @@

{{ i18n "resources" }}

    - + {{ $pathSections := split .Page.File "/" }} + {{ $path := printf "%s/%s/%s_%s.pdf" (index $pathSections 0) (index $pathSections 1) (index $pathSections 1) $.Site.Home.Language }} + {{ $pdfUrl := printf "%s%s/%s" $.Site.Params.downloadBaseUrl $.Site.Home.Language $path }} +
  • {{ i18n "download-pdf" }}
  • {{ $editUrl := printf "%s%s/%s" $.Site.Params.editBaseUrl $.Site.Home.Language .Page.File }}
  • {{ i18n "edit-page" }}