summaryrefslogtreecommitdiff
path: root/.config
diff options
context:
space:
mode:
Diffstat (limited to '.config')
-rw-r--r--.config/conkerorrc55
-rw-r--r--.config/hgrc2
-rw-r--r--.config/maildirproc/default.rc362
-rw-r--r--.config/maildirproc/purdue.rc84
-rw-r--r--.config/offlineimaprc49
-rw-r--r--.config/symlinks13
6 files changed, 560 insertions, 5 deletions
diff --git a/.config/conkerorrc b/.config/conkerorrc
new file mode 100644
index 0000000..e33add1
--- /dev/null
+++ b/.config/conkerorrc
@@ -0,0 +1,55 @@
+/* -*- Mode: js -*- */
+session_pref("signon.rememberSignons", true);
+session_pref("signon.expireMasterPassword", false);
+session_pref("signon.SignonFileName", "signons.txt");
+
+define_webjump("ddg", "https://duckduckgo.com/?q=%s");
+
+// Load login manager
+Components.classes["@mozilla.org/login-manager;1"].getService(Components.interfaces.nsILoginManager);
+
+// Auto complete stuff
+minibuffer_auto_complete_default = true;
+url_completion_use_history = true; // should work since bf05c87405
+url_completion_use_bookmarks = true;
+
+// Prompt before closing
+//define_key(content_buffer_normal_keymap, "C-x C-c", "confirm-quit");
+//can_kill_last_buffer = false;
+
+// Workaround for scrollbar bug (issue351)
+add_hook("create_buffer_late_hook",
+ function (buffer) {
+ buffer.top_frame.scrollbars.visible = true;
+ });
+
+// load session module
+require("session.js");
+session_auto_save_auto_load = true; // auto-load session
+
+// Don't show a clock in the modeline
+remove_hook("mode_line_hook", mode_line_adder(clock_widget));
+
+// Add favicons to the modeline
+require("favicon");
+add_hook("mode_line_hook", mode_line_adder(buffer_icon_widget), true);
+read_buffer_show_icons = true;
+
+// load firebug lite
+define_variable("firebug_url",
+ "https://getfirebug.com/firebug-lite.js");
+
+function firebug (I) {
+ var doc = I.buffer.document;
+ var script = doc.createElement('script');
+ script.setAttribute('type', 'text/javascript');
+ script.setAttribute('src', firebug_url);
+ script.setAttribute('onload', 'firebug.init();');
+ doc.body.appendChild(script);
+}
+interactive("firebug", "open firebug lite", firebug);
+
+// Make middle-click open links in a new buffer
+require("clicks-in-new-buffer.js");
+clicks_in_new_buffer_target = OPEN_NEW_BUFFER_BACKGROUND;
+clicks_in_new_buffer_button = 1;
diff --git a/.config/hgrc b/.config/hgrc
new file mode 100644
index 0000000..96fce82
--- /dev/null
+++ b/.config/hgrc
@@ -0,0 +1,2 @@
+[ui]
+username = Luke Shumaker <lukeshu@sbcglobal.net>
diff --git a/.config/maildirproc/default.rc b/.config/maildirproc/default.rc
new file mode 100644
index 0000000..ecea80f
--- /dev/null
+++ b/.config/maildirproc/default.rc
@@ -0,0 +1,362 @@
+# -*- mode: python; -*-
+
+import subprocess
+
+processor.maildir_base = "~/Maildir"
+processor.auto_reload_rcfile = True
+
+def is_to_or_from(mail,address):
+ """
+ Return true if [mail] is to or from an address that contains [address].
+ """
+ return (
+ False
+ or mail["From"].contains(address)
+ or mail["Reply-To"].contains(address)
+ or mail.target.contains(address))
+def is_to_or_from_re(mail,address):
+ """
+ Return true if [mail] is to or from an address that matches the
+ regex [address].
+ """
+ return (
+ mail["From"].matches(address)
+ or mail.target.matches(address))
+
+def bogofilter_auto(mail):
+ p = subprocess.Popen(
+ ["bogofilter", "-u", "-v", "-I", mail.path],
+ stdout=subprocess.PIPE,
+ stderr=subprocess.STDOUT)
+ (output, _) = p.communicate()
+ processor.log("*** Bogofilter result: {0!r}".format(output.rstrip()))
+ if p.returncode not in [0, 1, 2]:
+ processor.log_error(
+ "Error running bogofilter: Return code = {0!r}".format(
+ p.returncode))
+ return p.returncode
+
+def bogofilter_ham(mail):
+ subprocess.call(["bogofilter", "-S", "-n", "-I", mail.path])
+
+def bogofilter_spam(mail):
+ subprocess.call(["bogofilter", "-N", "-s", "-I", mail.path])
+
+def handle_incoming_spam_training(mail):
+ bogofilter_spam(mail)
+ mail.move(".Bulk Mail")
+
+def handle_incoming_ham_training(mail):
+ bogofilter_ham(mail)
+ handle_incoming_ham(mail)
+
+def handle_incoming_ham(mail):
+ my_filters(mail)
+def handle_incoming_spam(mail):
+ mail.move(".Bulk Mail")
+
+def handle_incoming_unknown(mail):
+ # Filter spam
+
+ spam = bogofilter_auto(mail)
+ if spam == 0:
+ handle_incoming_spam(mail)
+ return
+ elif spam == 1:
+ handle_incoming_ham(mail)
+ return
+ elif spam == 2:
+ # maybe spam
+ return
+ else:
+ mail.move(".Error")
+ return
+
+def my_filters(mail):
+ # Sort mail from GNU mailing lists
+ for list in [ 'bug-gsrc', 'bug-make', 'help-make', 'social', 'help-grub', 'bug-gnuzilla' ]:
+ if (
+ False
+ or mail["List-Id"].matches(list+"\.gnu\.org")
+ or mail["Subject"].contains(list)
+ ):
+ mail.move(".software."+list)
+ return
+
+ # Sort mail from other software mailing lists
+ if (
+ False
+ or mail["List-Id"].matches("social-discuss\.gnu\.org")
+ or mail["Subject"].contains("social-discuss")
+ ):
+ mail.move(".software.social")
+ return
+
+ if mail["List-Id"].matches("networkmanager-list\.gnome\.org"):
+ mail.move(".software.networkmanager")
+ return
+
+ if mail["List-Id"].matches("maintenance.lists.parabolagnulinux.org"):
+ mail.move(".software.parabola-maintenance")
+ return
+ if (
+ False
+ or mail["List-Id"].matches("parabolagnulinux.org")
+ or is_to_or_from(mail, "parabolagnulinux.org")
+ or is_to_or_from(mail, "kiwwwi.com.ar")
+ or is_to_or_from(mail, "parabola.nu")
+ ):
+ mail.move(".software.parabola-dev")
+ return
+
+ if (mail["List-Id"].matches("pacman-dev.archlinux.org")):
+ mail.move(".software.pacman-dev")
+ return
+
+ for subject_re in [
+ "\[Stow-[^\]]*\].*",
+ ]:
+ if mail["Subject"].matches(subject_re):
+ mail.move(".software")
+ return
+
+ # Sort mail from some social websites
+ if mail["From"].matches("facebook(|mail)\.com"):
+ mail.move(".Social.Facebook")
+ return
+
+ if (
+ False
+ or mail["From"].matches("identi\.ca")
+ or mail["From"].matches("statusnet")
+ ):
+ mail.move(".Social.Identica")
+ return
+
+ if mail["From"].matches("twitter\.com"):
+ mail.move(".Social.Twitter")
+ return
+
+ if mail["From"].matches("@xkcd\.com"):
+ mail.move(".Social.xkcd")
+ return
+
+ # Sort mail related to Troop 276
+ if (
+ False
+ or mail["List-Id"].contains("troopmailinglist.troop276.net")
+ or is_to_or_from(mail,"t276_announcements@att.net")
+ or mail["Subject"].matches("troop")
+ or mail["Subject"].matches("merit\s*badge")
+ or is_to_or_from(mail,"jsting@sbcglobal.net")
+ or is_to_or_from(mail,"trdindy@comcast.net")
+ or is_to_or_from(mail,"wjensen111@aol.com")
+ or is_to_or_from(mail,"dhoyt@yourhomecompany.com")
+ or is_to_or_from(mail,"salupo_vincent_p@lilly.com")
+ or is_to_or_from(mail,"basu@maharjan.org")
+ or is_to_or_from(mail,"muellerindy@yahoo.com")
+ or is_to_or_from(mail,"solorzano.luis@rocketmail.com")
+ or is_to_or_from(mail,"eldredmac@comcast.net")# MacDonell
+ or is_to_or_from(mail,"mitchprather@sbcglobal.net")
+ or is_to_or_from(mail,"oa_wap@yahoo.com")
+ or is_to_or_from(mail,"mytroop.us")
+ ):
+ mail.move(".Troop276")
+ return
+
+ # Sort mail from misc people
+ if mail["From"].matches("margieshu@sbcglobal\.net"):
+ mail.move(".misc.Mom")
+ return
+
+ for address in [
+ "justicejade10@aol.com",
+ "parsonsjade@aol.com",
+ "parsonstjade@gmail.com",
+ "jadparso@umail.iu.edu",
+ ]:
+ if mail["From"].contains(address):
+ mail.move(".misc.Jade")
+ return
+
+ for address in [
+ "nintendo.com",
+ "nintendo-news.com",
+ ]:
+ if mail["From"].contains(address):
+ mail.move(".misc.Nintendo")
+ return
+
+ for address in [
+ "@lpi.org",
+ "@pearson.com",
+ "CompTIA",
+ ]:
+ if mail["From"].contains(address):
+ mail.move(".misc.CompTIA")
+ return
+
+ # Sort mail from FRC people
+ for address in [
+ "@ni.com",
+ "@usfirst.org",
+ "BBonahoom@stanleyworks.com",
+ "allison.m.babcock@gmail.com",
+ "bryanbonahoom@gmail.com",
+ "cdewalt3@yahoo.com",
+ "dave.nelson@ecolab.com",
+ "dickaustin190@yahoo.com",
+ "djnels1@comcast.net", # Dave and Julie Nelson
+ "gamefreak207@gmail.com", # Brett Leedy
+ "jason.zielke@gmail.com",
+ "jeffreysmith@msdlt.k12.in.us",
+ "sarahlittell@comcast.net",
+ "silioso@gmail.com",
+ "skiplittell@comcast.net",
+ "tswilson4801@att.net",
+ "wcxctrack829@aim.com", # Pat
+ "william.walk@gmail.com",
+ ]:
+ if is_to_or_from(mail,address):
+ mail.move(".School.Robotics")
+ return
+ for subject_re in [
+ "FIRST",
+ "robotics",
+ "1024",
+ "kil-?a-?bytes",
+ ]:
+ if mail["Subject"].matches(subject_re):
+ mail.move(".School.Robotics")
+ return
+
+ # Sort mail from software people
+ for address in [
+ "gnu.org",
+ "gnome.org",
+ "eff.org",
+ "gitorious.org",
+ "sourceforge.com",
+ "ietf.org",
+ "kde.org",
+ "trustees@core3.amsl.com",
+ "esr@thyrsus.com",
+ "canonical.org",
+ "foocorp.net",
+ "cnuk.org",
+ "@archlinux.org",
+ "@github.com",
+ ]:
+ if is_to_or_from(mail,address):
+ mail.move(".software")
+ return
+
+
+ # Sort mail from the school newspaper
+ if (
+ False
+ or is_to_or_from(mail, "@lnnorthstar.org")
+ or is_to_or_from(mail, "lnnorthstar.org@tigertech.net")
+ ):
+ mail.move(".School.Newspaper")
+ return
+
+ # Sort mail from various employers/people who pay me
+ if is_to_or_from(mail, "@precisepath.com"):
+ mail.move(".Work.PrecisePath")
+ return
+
+ if is_to_or_from(mail,"susyphil@aol.com"):
+ mail.move(".Work.PMCH")
+
+ for address in [
+ "d.farrar@comcast.net",
+ "dfarrar@avacoustics.net",
+ "@vmware.com",
+ ]:
+ if is_to_or_from(mail,address):
+ mail.move(".Work.FAST")
+ return
+
+ # Sort misc newsletters
+ if (
+ False
+ or mail["From"].contains("newsletter")
+ or mail["From"].contains("auto@comicsbyemail.com")
+ or mail["From"].contains("oreilly.com")
+ or mail["Subject"].contains("newsletter")
+ or mail["From"].contains("Info@mailing.jamendo.com")
+ or mail["From"].contains("info@demandprogress.org")
+ ):
+ mail.move(".misc.Newsletters")
+ return
+
+ if (
+ False
+ or mail["From"].contains("@msdlt.k12.in.us")
+ or mail["From"].contains("naviance.com")
+ or is_to_or_from(mail,"ibwhite@comcast.net")
+ or mail["Subject"].contains("IOA")
+ or mail["From"].contains("nths.org")
+ or mail["Subject"].contains("NTHS")
+ or mail["Subject"].contains("National Technical Honor Society")
+ or mail["Subject"].contains("NHS")
+ or mail["Subject"].contains("National Honor Society")
+ ):
+ mail.move(".School")
+ return
+
+ # from college stuff
+ if (
+ False
+ or mail["Subject"].contains("NYLF") # National Youth Leadership Conference
+ or mail["Subject"].contains("NSHSS")
+ ):
+ mail.move(".College.Societies")
+ return
+ if (
+ False
+ #or mail["From"].contains(".edu")
+ or mail["From"].contains("admissions@")
+ #or mail["From"].contains("college")
+ #or mail["From"].contains("university")
+ or mail["Subject"].contains("college")
+ # now we get to the BS
+ or mail["From"].contains("@dreamitdoitindiana.com")
+ or mail["From"].contains("@indianatechinfo.org")
+ ):
+ mail.move(".College")
+ return
+
+ if mail["From"].contains("@projectwonderful.com"):
+ mail.move(".ProjectWonderful")
+ return
+
+ if (
+ False
+ or mail["From"].matches("@localhost")
+ or mail["From"].matches("@[^,>]*\.local")
+ or mail["From"].matches("@[^,>]*\.lukeshu\.ath\.cx")
+ or mail["To"].matches("luke@")
+ ):
+ mail.move(".LocalSystems")
+ return
+ if (
+ False
+ or mail["Subject"].contains("password")
+ or mail["Subject"].contains("account")
+ ):
+ mail.move(".misc.accounts")
+ return
+
+ mail.move(".Ham")
+
+handle_mapping = {
+ ".": handle_incoming_unknown,
+ ".spam-training": handle_incoming_spam_training,
+ ".ham-training": handle_incoming_ham_training,
+ #".Ham": handle_incoming_ham,
+ }
+processor.maildirs = handle_mapping.keys()
+for mail in processor:
+ handle_mapping[mail.maildir](mail)
diff --git a/.config/maildirproc/purdue.rc b/.config/maildirproc/purdue.rc
new file mode 100644
index 0000000..9a759f5
--- /dev/null
+++ b/.config/maildirproc/purdue.rc
@@ -0,0 +1,84 @@
+# -*- mode: python; -*-
+
+import subprocess
+
+processor.maildir_base = "~/Maildir.purdue"
+processor.auto_reload_rcfile = True
+
+def is_to_or_from(mail,address):
+ """
+ Return true if [mail] is to or from an address that contains [address].
+ """
+ return (
+ mail["From"].contains(address)
+ or mail.target.contains(address))
+def is_to_or_from_re(mail,address):
+ """
+ Return true if [mail] is to or from an address that matches the
+ regex [address].
+ """
+ return (
+ mail["From"].matches(address)
+ or mail.target.matches(address))
+
+def piazza_topic(mail, topic):
+ return (
+ is_to_or_from(mail, topic+" on Piazza")
+ or mail["Subject"].contains(topic+" on Piazza"))
+
+def my_filters(mail):
+ # Generic stuff ########################################################
+
+ if mail["Subject"].contains("[PASE]"):
+ mail.move("INBOX.PASE")
+ return
+
+ if mail["Subject"].contains("[PLUG]"):
+ mail.move("INBOX.PLUG")
+ return
+
+ if is_to_or_from(mail,"linkedin.com"):
+ mail.move("INBOX.LinkedIn")
+ return
+
+ if (
+ False
+ or mail["Subject"].contains("[CS Opportunity Update]")
+ or mail["Subject"].contains("[CS Majors]")
+ ):
+ mail.move("INBOX.CS")
+ return
+
+ # Fall 2012 ############################################################
+
+ if mail["Subject"].contains("Fall-2012-SCI-21000-001:"):
+ mail.move("INBOX.classes.2012-2.SCI210")
+ if mail["Subject"].contains("fall-2012-cs-18000"):
+ mail.move("INBOX.classes.2012-2.CS180")
+ return
+ if piazza_topic(mail, "CS 18000"):
+ mail.move("INBOX.classes.2012-2.CS180.Piazza")
+ return
+ if mail["Subject"].contains("Fall-2012-SOC-10000"):
+ mail.move("INBOX.classes.2012-2.SOC100")
+ return
+
+ # Spring 2013 ##########################################################
+
+ if mail["Subject"].contains("[CS240]") or mail["Subject"].contains("Spring-2013-CS-24000"):
+ mail.move("INBOX.classes.2013-1.CS240")
+ return
+ if piazza_topic(mail, "CS 240"):
+ mail.move("INBOX.classes.2013-1.CS240.Piazza")
+ return
+
+ if mail["Subject"].contains("Spring-2013-CS-18200"):
+ mail.move("INBOX.classes.2013-1.CS182")
+ return
+
+handle_mapping = {
+ "INBOX": my_filters,
+ }
+processor.maildirs = handle_mapping.keys()
+for mail in processor:
+ handle_mapping[mail.maildir](mail)
diff --git a/.config/offlineimaprc b/.config/offlineimaprc
new file mode 100644
index 0000000..8ea8f30
--- /dev/null
+++ b/.config/offlineimaprc
@@ -0,0 +1,49 @@
+# -*- Mode: Conf -*-
+[general]
+accounts = ATT,Purdue
+
+## AT&T ###############################################################
+
+[Account ATT]
+localrepository = Local-Main
+remoterepository = Remote-SBCGlobal
+
+[Repository Local-Main]
+type = Maildir
+localfolders = ~/Maildir
+sep = .
+folderfilter = lambda foldername: not re.search('(Trash|Del|-old|Draft)', foldername)
+# transforms local -> remote
+nametrans = lambda foldername: re.sub('^$', 'Inbox', re.sub('^'+re.escape('%(sep)s'), '', foldername))
+
+[Repository Remote-SBCGlobal]
+type = IMAP
+ssl = yes
+cert_fingerprint = 700d84baa7e852240178dc2de18e7e528a2854df
+remotehost = imap.mail.yahoo.com
+remoteuser = lukeshu@sbcglobal.net
+folderfilter = lambda foldername: not re.search('(Trash|Del)', foldername)
+
+# transforms remote -> local
+# we must assume that sep=/ on the remote IMAP server.
+nametrans = lambda foldername: '/'+re.sub('^Inbox$', '', foldername)
+
+## Purdue ############################################################
+
+[Account Purdue]
+localrepository = Local-Purdue
+remoterepository = Remote-Purdue
+
+[Repository Local-Purdue]
+type = Maildir
+localfolders = ~/Maildir.purdue
+sep = .
+folderfilter = lambda foldername: re.search('INBOX', foldername)
+
+[Repository Remote-Purdue]
+type = IMAP
+ssl = yes
+cert_fingerprint = 32bdd134cad8da1bea57aa379b98b1cff692e4fd
+remotehost = mymail.purdue.edu
+remoteuser = shumakl
+folderfilter = lambda foldername: re.search('INBOX', foldername)
diff --git a/.config/symlinks b/.config/symlinks
index cd38e2f..2cbe055 100644
--- a/.config/symlinks
+++ b/.config/symlinks
@@ -7,10 +7,6 @@
.config/bash/login.sh .bash_login
.config/bash/logout.sh .bash_logout
-.config/git/ignore .gitignore
-.config/git/config .gitconfig
-.config/git/gitk .gitk
-
.config/arduino/ .arduino
.config/bazaar/ .bazaar
.config/emacs/ .emacs.d
@@ -22,7 +18,14 @@
.config/ssh/ .ssh #
.config/subversion/ .subversion
.config/wmii/ .wmii
-
+.config/mplayer/ .mplayer
+.config/purple/ .purple
+.config/cpan/ .cpan
+.config/maildirproc .maildirproc
+.config/offlineimaprc .offlineimaprc
+.config/conkerorrc .conkerorrc
+.config/hgrc .hgrc
+.config/linphonerc .linphonerc
.config .kde/share/apps
.config .kde/share/config