]> git.madduck.net Git - etc/mutt.git/blobdiff - .lbdbrc

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:

add icalparser
[etc/mutt.git] / .lbdbrc
diff --git a/.lbdbrc b/.lbdbrc
index a66f67c838d27de329580571efbf5895e61c3c3c..6420898497ab0bb336d208fec8023b030c397e13 100644 (file)
--- a/.lbdbrc
+++ b/.lbdbrc
@@ -1,17 +1,14 @@
-CONTACTS_DIR=$HOME/contacts
+METHODS=m_gpg
 
 : ${TMPDIR:=/tmp}
 
 
 : ${TMPDIR:=/tmp}
 
+CONTACTS_DIR=$HOME/contacts
 if [ -d $CONTACTS_DIR ]; then
   METHODS="$METHODS m_vcf"
   VCF_FILES="$TMPDIR/lbdbq.vcf"
 if [ -d $CONTACTS_DIR ]; then
   METHODS="$METHODS m_vcf"
   VCF_FILES="$TMPDIR/lbdbq.vcf"
-
-  VCF_TEMP="$(tempfile -d $TMPDIR -p lbdbq -s .vcf)"
-  cleanup() { rm -f $VCF_TEMP; trap - EXIT; }
-
-  for i in $CONTACTS_DIR/*; do case "${i##*/}" in ICE*) continue;; esac; cat "$i"; echo \r; done >| "$VCF_TEMP"
-  if ! cmp "$VCF_FILES" "$VCF_TEMP"; then
+  VCF_TEMP="$tmpdir/contacts.vcf"
+  for i in $CONTACTS_DIR/*; do case "${i##*/}" in ICE*) continue;; esac; cat "$i"; done >| "$VCF_TEMP"
+  if ! cmp --quiet "$VCF_FILES" "$VCF_TEMP"; then
     mv "$VCF_TEMP" "$VCF_FILES"
   fi
     mv "$VCF_TEMP" "$VCF_FILES"
   fi
-  cleanup
 fi
 fi