diff --git a/bin/omarchy-refresh-pacman b/bin/omarchy-refresh-pacman index 1d20cae3..c968a36a 100755 --- a/bin/omarchy-refresh-pacman +++ b/bin/omarchy-refresh-pacman @@ -5,11 +5,11 @@ sudo cp -f ~/.local/share/omarchy/default/pacman/pacman.conf /etc/pacman.conf if [[ $1 == "edge" ]]; then sudo cp -f ~/.local/share/omarchy/default/pacman/mirrorlist-edge /etc/pacman.d/mirrorlist sudo sed -i 's|https://pkgs.omarchy.org/.*$arch|https://pkgs.omarchy.org/edge/$arch|' /etc/pacman.conf - echo "Setting mirror and pkgs channel to edge" + echo "Setting channel to edge" else sudo cp -f ~/.local/share/omarchy/default/pacman/mirrorlist-stable /etc/pacman.d/mirrorlist sudo sed -i 's|https://pkgs.omarchy.org/.*$arch|https://pkgs.omarchy.org/stable/$arch|' /etc/pacman.conf - echo "Setting mirror and pkgs channel to stable" + echo "Setting channel to stable" fi echo diff --git a/bin/omarchy-version-channel b/bin/omarchy-version-channel new file mode 100755 index 00000000..8affb87e --- /dev/null +++ b/bin/omarchy-version-channel @@ -0,0 +1,23 @@ +#!/bin/bash + +if grep -q "https://stable-mirror.omarchy.org/" /etc/pacman.d/mirrorlist; then + mirror="stable" +elif grep -q "https://mirror.omarchy.org/" /etc/pacman.d/mirrorlist; then + mirror="edge" +else + mirror="unknown" +fi + +if grep -q "https://pkgs.omarchy.org/stable/" /etc/pacman.conf; then + pkgs="stable" +elif grep -q "https://pkgs.omarchy.org/edge/" /etc/pacman.conf; then + pkgs="edge" +else + pkgs="unknown" +fi + +if [[ $mirror == $pkgs ]]; then + echo $mirror +else + echo "$mirror / $pkgs" +fi diff --git a/bin/omarchy-version-mirror b/bin/omarchy-version-mirror deleted file mode 100755 index 88d6e697..00000000 --- a/bin/omarchy-version-mirror +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/bash - -if grep -q "https://stable-mirror.omarchy.org/" /etc/pacman.d/mirrorlist; then - echo "stable" -elif grep -q "https://mirror.omarchy.org/" /etc/pacman.d/mirrorlist; then - echo "edge" -else - echo "unknown" -fi diff --git a/bin/omarchy-version-pkgs b/bin/omarchy-version-pkgs deleted file mode 100755 index 4c384107..00000000 --- a/bin/omarchy-version-pkgs +++ /dev/null @@ -1,9 +0,0 @@ -#!/bin/bash - -if grep -q "https://pkgs.omarchy.org/stable/" /etc/pacman.conf; then - echo "stable" -elif grep -q "https://pkgs.omarchy.org/edge/" /etc/pacman.conf; then - echo "edge" -else - echo "unknown" -fi diff --git a/config/fastfetch/config.jsonc b/config/fastfetch/config.jsonc index 607210c0..58371fa7 100644 --- a/config/fastfetch/config.jsonc +++ b/config/fastfetch/config.jsonc @@ -76,15 +76,9 @@ }, { "type": "command", - "key": "│ ├󱞠", + "key": "│ ├󰔫", "keyColor": "blue", - "text": "mirror=$(omarchy-version-mirror); echo \"$mirror\"" - }, - { - "type": "command", - "key": "│ ├", - "keyColor": "blue", - "text": "pkgs=$(omarchy-version-pkgs); echo \"$pkgs\"" + "text": "channel=$(omarchy-version-channel); echo \"$channel\"" }, { "type": "kernel",