]> git.madduck.net Git - etc/offlineimap.git/commitdiff

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

encapsulate preauthtunnel in script
authormartin f. krafft <madduck@madduck.net>
Sun, 22 Mar 2020 03:39:51 +0000 (16:39 +1300)
committermartin f. krafft <madduck@madduck.net>
Sun, 22 Mar 2020 03:39:51 +0000 (16:39 +1300)
.gitignore.d/offlineimap
.offlineimap/preauthtunnel.sh [new file with mode: 0755]
.offlineimaprc

index 7acdc907519e1d142f02354524d9a4808fc083a6..03dcd57f8f6231345d2c95e0e87e181e5500ff95 100644 (file)
@@ -6,6 +6,7 @@
 !/.offlineimap/.gitignore
 !/.offlineimap/helper.py
 !/.offlineimap/known_hosts
 !/.offlineimap/.gitignore
 !/.offlineimap/helper.py
 !/.offlineimap/known_hosts
+!/.offlineimap/preauthtunnel.sh
 !/.offlineimaprc
 !/.offlineimap/ssh_config
 !/.var/offlineimap/.gitignore
 !/.offlineimaprc
 !/.offlineimap/ssh_config
 !/.var/offlineimap/.gitignore
diff --git a/.offlineimap/preauthtunnel.sh b/.offlineimap/preauthtunnel.sh
new file mode 100755 (executable)
index 0000000..0976974
--- /dev/null
@@ -0,0 +1,3 @@
+#!/bin/sh
+
+exec ssh -F ~/.offlineimap/ssh_config -i ~/.offlineimap/${1}.ssh-seckey ${1}
index aa7267cd654d4f80ed2ace4326d5aa0bac4a90d3..bcc8bbc6fee8030594b9b98bbdddb568b8aecf4c 100644 (file)
@@ -40,7 +40,7 @@ type = IMAP
 maxconnections = 5
 holdconnectionopen = yes
 ssh_host = madduck-net.imap.madduck.net
 maxconnections = 5
 holdconnectionopen = yes
 ssh_host = madduck-net.imap.madduck.net
-preauthtunnel = ssh -F ~/.offlineimap/ssh_config -i ~/.offlineimap/%(ssh_host)s.ssh-seckey %(ssh_host)s
+preauthtunnel = .offlineimap/preauthtunnel.sh %(ssh_host)s
 expunge = yes
 foldersort = py_foldersort_main
 nametrans = py_nametrans
 expunge = yes
 foldersort = py_foldersort_main
 nametrans = py_nametrans
@@ -51,7 +51,7 @@ type = IMAP
 maxconnections = 1
 holdconnectionopen = no
 ssh_host = madduck-net.imap.madduck.net
 maxconnections = 1
 holdconnectionopen = no
 ssh_host = madduck-net.imap.madduck.net
-preauthtunnel = ssh -F ~/.offlineimap/ssh_config -i ~/.offlineimap/%(ssh_host)s.ssh-seckey %(ssh_host)s
+preauthtunnel = .offlineimap/preauthtunnel.sh %(ssh_host)s
 expunge = yes
 folderfilter = py_folderfilter_bulk
 foldersort = py_foldersort_main
 expunge = yes
 folderfilter = py_folderfilter_bulk
 foldersort = py_foldersort_main