aboutsummaryrefslogtreecommitdiff
path: root/toggle-multilib/vim.sh
diff options
context:
space:
mode:
Diffstat (limited to 'toggle-multilib/vim.sh')
-rwxr-xr-xtoggle-multilib/vim.sh3
1 files changed, 3 insertions, 0 deletions
diff --git a/toggle-multilib/vim.sh b/toggle-multilib/vim.sh
new file mode 100755
index 0000000..644e82c
--- /dev/null
+++ b/toggle-multilib/vim.sh
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+grep '^\[multilib]' /etc/pacman.conf >/dev/null && sudo vim /etc/pacman.conf '+%s/^\(\[multilib]\)\n\(.*\)/#\1\r#\2' +x || sudo vim /etc/pacman.conf '+%s/^#\(\[multilib\]\)\n#\(.*\)/\1\r\2' +x