From 7a271485c808054654cd70728f023726209aedfc Mon Sep 17 00:00:00 2001
From: Christoph Berg
Date: Tue, 16 Apr 2024 14:04:11 +0200
Subject: [PATCH] download/debian,ubuntu: Support 2nd "copy script" button
---
media/js/download.js | 7 ++++++-
templates/pages/download/linux/debian.html | 4 ++--
templates/pages/download/linux/ubuntu.html | 4 ++--
3 files changed, 10 insertions(+), 5 deletions(-)
diff --git a/media/js/download.js b/media/js/download.js
index 5faa3800..8493ef06 100644
--- a/media/js/download.js
+++ b/media/js/download.js
@@ -16,12 +16,17 @@ function setupHandlers() {
});
}
- /* Copy Script button on /download/linux/debian and /download/linux/ubuntu */
+ /* Copy Script buttons on /download/linux/debian and /download/linux/ubuntu */
if (document.getElementById("copy-btn") && document.getElementById("script-box")) {
document.getElementById('copy-btn').addEventListener('click', function () {
copyScript(this, 'script-box');
});
}
+ if (document.getElementById("copy-btn2") && document.getElementById("script-box2")) {
+ document.getElementById('copy-btn2').addEventListener('click', function () {
+ copyScript(this, 'script-box2');
+ });
+ }
}
document.addEventListener("DOMContentLoaded", setupHandlers);
diff --git a/templates/pages/download/linux/debian.html b/templates/pages/download/linux/debian.html
index 919c5c92..8f628deb 100644
--- a/templates/pages/download/linux/debian.html
+++ b/templates/pages/download/linux/debian.html
@@ -67,7 +67,7 @@ To manually configure the Apt repository, follow these steps:
-
# Import the repository signing key:
+
# Import the repository signing key:
sudo apt install curl ca-certificates
sudo install -d /usr/share/postgresql-common/pgdg
sudo curl -o /usr/share/postgresql-common/pgdg/apt.postgresql.org.asc --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc
@@ -81,7 +81,7 @@ sudo apt update
# Install the latest version of PostgreSQL:
# If you want a specific version, use 'postgresql-16' or similar instead of 'postgresql'
sudo apt -y install postgresql
-
+
diff --git a/templates/pages/download/linux/ubuntu.html b/templates/pages/download/linux/ubuntu.html
index f721ba30..19c0a318 100644
--- a/templates/pages/download/linux/ubuntu.html
+++ b/templates/pages/download/linux/ubuntu.html
@@ -66,7 +66,7 @@ To manually configure the Apt repository, follow these steps:
-
# Import the repository signing key:
+
# Import the repository signing key:
sudo apt install curl ca-certificates
sudo install -d /usr/share/postgresql-common/pgdg
sudo curl -o /usr/share/postgresql-common/pgdg/apt.postgresql.org.asc --fail https://www.postgresql.org/media/keys/ACCC4CF8.asc
@@ -80,7 +80,7 @@ sudo apt update
# Install the latest version of PostgreSQL:
# If you want a specific version, use 'postgresql-16' or similar instead of 'postgresql'
sudo apt -y install postgresql