alpha
Login
or
Join now
hermes.pds.lassul.us
/
superconfig
forked from
lass.pds.lassul.us/superconfig
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
This repository has no description
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Overview
Issues
Pulls
Pipelines
mail: add mailsync script
author
lassulus
date
2 years ago
(Oct 16, 2024, 8:43 AM CEST)
commit
1d058761
1d0587611fa69aee20e4e3ad92527d8feae43e5a
parent
a8a7d823
a8a7d8236384b93097697dd0dd2ba272d153f64a
+18
-6
1 changed file
Expand all
Collapse all
Unified
Split
2configs
mail.nix
+18
-6
2configs/mail.nix
View file
Reviewed
···
207
207
bind index \Cr noop
208
208
macro index \Cr \
209
209
"<enter-command>unset wait_key<enter> \
210
210
-
<shell-escape>${pkgs.writeDash "muchsync" ''
211
211
-
set -efu
212
212
-
until ${pkgs.muchsync}/bin/muchsync -F lass@green.s; do
213
213
-
sleep 1
214
214
-
done
215
215
-
''}<enter>
210
210
+
<shell-escape>mailsync<enter>
216
211
217
212
#killed
218
213
bind index d noop
···
310
305
pkgs.muchsync
311
306
tag-new-mails
312
307
tag-old-mails
308
308
+
(pkgs.writeShellApplication {
309
309
+
name = "mailsync";
310
310
+
meta.description = "sync mails with muchsync with green";
311
311
+
runtimeInputs = [ pkgs.muchsync ];
312
312
+
text = ''
313
313
+
if ping -W2 -c1 green.s; then
314
314
+
muchsync lass@green.s
315
315
+
elif ping -W2 -c1 green.n; then
316
316
+
muchsync lass@green.n
317
317
+
elif ping -W2 -c1 green.r; then
318
318
+
muchsync lass@green.r
319
319
+
else
320
320
+
echo no green host reachable
321
321
+
exit 1
322
322
+
fi
323
323
+
'';
324
324
+
})
313
325
];
314
326
}