<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -36,8 +36,23 @@
            (setq mappings nil))
           (t (setq mappings (cdr mappings))) )))
 
+(defun jw-track-go-directories (string)
+  (let ((out (replace-regexp-in-string &quot;\n$&quot; &quot;&quot; string)))
+    (if (string-match &quot;\\[cd: \\(.*\\)\\]&quot; out)
+        (let ((dir (substring out (match-beginning 1) (match-end 1))))
+          (jw-cd dir) ))))
+
 (defun jw-tracker (string) 
   (let ((cmd (replace-regexp-in-string &quot;\n$&quot; &quot;&quot; string)))
     (jw-check-dir-mappings cmd jw-directory-mappings) ))
 
+;;; Add the hooks
+
 (add-hook 'comint-input-filter-functions 'jw-tracker)
+(add-hook 'comint-output-filter-functions 'jw-track-go-directories)
+
+;;; Debugging --------------------------------------------------------
+
+(defun jw-debug-tracker (string)
+  (message (concat &quot;TRACKING STRING: '&quot; string &quot;'&quot;)))
+</diff>
      <filename>ini/cd-tracking.el</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>88730c6f0bed91094e564023d39238b1200d9e12</id>
    </parent>
  </parents>
  <author>
    <name>Jim Weirich</name>
    <email>jim.weirich@gmail.com</email>
  </author>
  <url>http://github.com/jimweirich/emacs-setup/commit/a1e4aaa388deafb9254d65653e96fc0ab6294b7b</url>
  <id>a1e4aaa388deafb9254d65653e96fc0ab6294b7b</id>
  <committed-date>2009-06-30T12:31:24-07:00</committed-date>
  <authored-date>2009-06-30T12:31:24-07:00</authored-date>
  <message>Added improved cd directory tracking.</message>
  <tree>41bf131e876557b6a55df711e340e09e9f7c8b54</tree>
  <committer>
    <name>Jim Weirich</name>
    <email>jim.weirich@gmail.com</email>
  </committer>
</commit>
