rankmirrors

This commit is contained in:
Geoffrey Frogeye 2020-02-17 07:01:26 +01:00
parent fb06c9e19b
commit a6755863dd
6 changed files with 28 additions and 4 deletions

21
config/scripts/arch-rankmirrors Executable file
View file

@ -0,0 +1,21 @@
#!/usr/bin/env bash
set -e
if [ $USER != root ]
then
echo "This script should be run as root."
exit 1
fi
if ! pacman -Qq pacman-mirrorlist &> /dev/null
then
pacman -S pacman-mirrorlist
fi
if [ ! -f /etc/pacman.d/mirrorlist.pacnew ]
then
cp /etc/pacman.d/mirrorlist /etc/pacman.d/mirrorlist.pacnew
fi
egrep -o 'Server = .+' /etc/pacman.d/mirrorlist.pacnew | /usr/bin/rankmirrors -n 6 - > /etc/pacman.d/mirrorlist

View file

@ -223,7 +223,7 @@ hasInstaller() { # installerName
# Installers that install in the user directory
addUserInstallers() {
addInstaller Tapt # Termux
addInstaller Umakepkg
# addInstaller Umakepkg # TODO broken
addInstaller Upip
# addInstaller Upkgbuild
}

View file

@ -7,8 +7,10 @@ sudo pacman -S etckeeper --needed
sudo etckeeper commit "install-arch script: begin"
# Install yay
sudo pacman -S base-devel --needed
if ! pacman -Q yay &> /dev/null
then
sudo pacman -S go-pie --needed
mkdir -p $HOME/.cache/yay
cd $HOME/.cache/yay
curl -L https://aur.archlinux.org/cgit/aur.git/snapshot/yay.tar.gz | tar xzvf -

View file

@ -1,2 +0,0 @@
#!/usr/bin/env bash
egrep -o 'Server = .+' /etc/pacman.d/mirrorlist.pacnew | /usr/bin/rankmirrors-n6 - > /etc/pacman.d/mirrorlist

View file

@ -107,6 +107,7 @@ i tmux # Terminal multiplexer
i bash-completion # Shell completions
i fzf # Fancy file finder
i highlight # Syntax highlighter (TODO No termux)
i powerline-go # Nice prompt (potential problem: requires go-pie)
i zsh # Shell
# TODO Arch only for the following but not a problem
@ -114,6 +115,7 @@ i zsh-autosuggestions # Shell suggestions
i zsh-completions # Shell completions
i zsh-history-substring-search # Shell config
i zsh-syntax-highlighting # Shell highlighting
i rxvt-unicode-terminfo # So it doesn't act weird in root
# Text edition
(i neovim nvim && i python-neovim python3-neovim) || i vim || i vi # Text editor
@ -270,6 +272,7 @@ then
i vimpc-git # CLI UI MPD client
i musescore # Music sheet editor
i ashuffle # Auto-fill MPD playlist
i audacity # Audio editor
fi

View file

@ -79,7 +79,7 @@ Plug 'autozimu/LanguageClient-neovim', {
" Disabled : While it works correctly when typing code,
" when modifying existing one it's another thing
Plug 'ActivityWatch/aw-watcher-vim'
" Plug 'ActivityWatch/aw-watcher-vim'
" Activity watch
" (might not want this on every install)