                   "/ke/local/toolchain3-x86_64-nptl/tools/java/jdk1.6.0_13/bin:"
                   "/ke/local/toolchain3-x86_64-nptl/tools/java/ant-1.7.0/bin:"
                   (getenv "PATH"))))
+
+(defmacro ke/with-compilation-path (&rest body)
+  (let ((current-path (getenv "PATH")))
+    (ke/setup-path)
+    `(unwind-protect
+         (progn ,@body)
+       (setenv "PATH" ,current-path))))
 
 (defun ke/notify (text)
   (interactive "sInsert the text of the notification: ")

  "Remove white spaces in beginning and ending of STRING.
White space here is any of: space, tab, emacs newline (line feed, ASCII 10)."
  (replace-regexp-in-string "\\`[ \t\n]*" "" (replace-regexp-in-string "[ \t\n]*\\'" "" string)))

(defun ke/reset-path ()
  "Reset the path to the original one"
  (when ke/original-path (setenv "PATH" ke/original-path)))

(defun ke/find-root-dir (path look-for-member &optional discarded)
  "Recursively finds for a directory in the given path"

  "Set this to the location of your Bear binary"
  :group 'my/dotemacs)

(defun ke/setup-path ()
  "Sets the KE's path"
  (setenv "PATH"
          (concat "/ke/local/toolchain3-x86_64-nptl/bin:"
                  "/ke/local/toolchain3-x86_64-nptl/tools/bin:"
