aboutsummaryrefslogtreecommitdiff
path: root/bin/m
diff options
context:
space:
mode:
authorEuAndreh <eu@euandre.org>2022-11-06 20:36:00 -0300
committerEuAndreh <eu@euandre.org>2022-11-06 20:36:03 -0300
commit185517bc659e671d32b22ae5afe678594c84c692 (patch)
treef02103e65c9e1fd4276375ee45ee45b3d25629b2 /bin/m
parentetc/guix/home.scm: Include many alternative shells (diff)
downloaddotfiles-185517bc659e671d32b22ae5afe678594c84c692.tar.gz
dotfiles-185517bc659e671d32b22ae5afe678594c84c692.tar.xz
bin/m: Run mbsync in parallel, with one process per account
Get the accounts from the list generated by `mailcfg list`.
Diffstat (limited to 'bin/m')
-rwxr-xr-xbin/m4
1 files changed, 3 insertions, 1 deletions
diff --git a/bin/m b/bin/m
index 43b1ad6..6891128 100755
--- a/bin/m
+++ b/bin/m
@@ -59,6 +59,8 @@ done
shift $((OPTIND - 1))
+F="${XDG_DATA_HOME:-$HOME/.local/share}"/euandreh/mailcfg-accounts.txt
+
notmuch new
-mbsync -a
+xargs -I% -P "$(wc -l < "$F")" mbsync '%' < "$F"
notmuch new