aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2023-03-23 16:29:21 -0300
committerEuAndreh <eu@euandre.org>2023-03-23 16:29:21 -0300
commitfa6537934db8491f20eb3fdd39b38ea78c4c482b (patch)
tree927db4cd34db8b116622c379b8b5833adc491691
parentMakefile: Add architecture to check target name (diff)
downloadpackage-repository-fa6537934db8491f20eb3fdd39b38ea78c4c482b.tar.gz
package-repository-fa6537934db8491f20eb3fdd39b38ea78c4c482b.tar.xz
Use manual echo to /etc/apt/sources.list over apt-add-repository
-rw-r--r--README.md2
-rwxr-xr-xsrc/bin/paku.in9
-rwxr-xr-xtests/checks/deb.sh5
3 files changed, 9 insertions, 7 deletions
diff --git a/README.md b/README.md
index 99a87e6..16d8803 100644
--- a/README.md
+++ b/README.md
@@ -52,7 +52,7 @@ Adding the overlay to your `/etc/nixos/configuration.nix`:
```shell
$ wget -qO- https://euandre.org/s/package-repository/debian/public-key.asc | sudo tee /etc/apt/trusted.gpg.d/euandre.org.asc
-$ sudo apt-add-repository 'deb https://euandre.org/s/package-repository/debian ./'
+$ echo 'deb https://euandre.org/s/package-repository/debian ./' | sudo tee -a /etc/apt/sources.list
```
diff --git a/src/bin/paku.in b/src/bin/paku.in
index f914426..1bac0ba 100755
--- a/src/bin/paku.in
+++ b/src/bin/paku.in
@@ -664,11 +664,12 @@ sub emit_html() {
by adding its URL to
<code>/etc/apt/sources.list</code>:
</p>
- <pre><code>\$ sudo apt-add-repository 'deb $json->{'base-url'}/debian ./'</code></pre>
+ <pre><code>\$ echo 'deb $json->{'base-url'}/debian ./' |
+ sudo tee -a /etc/apt/sources.list
+ \$ sudo apt update</code></pre>
<p>
- <code>apt-add-repository</code> will already perform
- an <code>apt update</code>, so the packages from the
- new repository will already be available.
+ After that the packages from the new repository will
+ be available.
</p>
</article>
<article id="nix-instructions">
diff --git a/tests/checks/deb.sh b/tests/checks/deb.sh
index 90ed7f9..9a0ba7d 100755
--- a/tests/checks/deb.sh
+++ b/tests/checks/deb.sh
@@ -16,8 +16,9 @@ if apt info remembering; then
exit 1
fi
-wget -qO- "$REPO"/public-key.asc | sudo tee /etc/apt/trusted.gpg.d/"$KEY"
-sudo apt-add-repository "deb $REPO ./"
+wget -qO- "$REPO"/public-key.asc | sudo tee /etc/apt/trusted.gpg.d/"$KEY"
+echo "deb $REPO ./" | sudo tee -a /etc/apt/sources.list
+sudo apt update
sudo apt install remembering
remembering --help