From 303992f5ad5c625eb67acbaffabb3316c4bebefe Mon Sep 17 00:00:00 2001 From: Nikita Hasert Date: Fri, 23 May 2025 07:16:18 +0200 Subject: [PATCH] Add initialize_pacman script This script will initialize pacman-key and populate some keys in preparation for the other scripts in that directory --- README.md | 9 +++++++++ install_all | 5 +---- scripts/initialize_pacman | 4 ++++ 3 files changed, 14 insertions(+), 4 deletions(-) create mode 100644 scripts/initialize_pacman diff --git a/README.md b/README.md index af5461d..a782bec 100644 --- a/README.md +++ b/README.md @@ -24,6 +24,15 @@ To run all scripts, simply execute ./install_all ``` +If you want to run the scripts individually, make sure to execute `/scripts/initialize_pacman` beforehand, to initialize pacman-key and populate it with some trusted keys otherwise you may see this error for install scripts +```bash +warning: Public keyring not found; have you run 'pacman-key --init'? +downloading required keys... +error: keyring is not writable +error: required key missing from keyring +error: failed to commit transaction (could not find or read file) +``` + ## General Tools & Misc ### ./scripts/install_xclip diff --git a/install_all b/install_all index 181e268..06c775e 100755 --- a/install_all +++ b/install_all @@ -1,9 +1,6 @@ #!/bin/bash -sudo pacman-key --init -sudo pacman-key --populate archlinux -sudo pacman-key --populate holo -sudo pacman-key --refresh-keys +. scripts/initialize_pacman . scripts/install_lein . scripts/install_neovim diff --git a/scripts/initialize_pacman b/scripts/initialize_pacman new file mode 100644 index 0000000..36ff6b6 --- /dev/null +++ b/scripts/initialize_pacman @@ -0,0 +1,4 @@ +sudo pacman-key --init +sudo pacman-key --populate archlinux +sudo pacman-key --populate holo +sudo pacman-key --refresh-keys \ No newline at end of file