Skip to content

Instantly share code, notes, and snippets.

@Wilfred
Created June 17, 2015 09:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Wilfred/e7be1b540aa925c4e196 to your computer and use it in GitHub Desktop.
Save Wilfred/e7be1b540aa925c4e196 to your computer and use it in GitHub Desktop.
excorporate patches
diff --git a/elpa/excorporate-0.6.0/excorporate-calfw.el b/elpa/excorporate-0.6.0/excorporate-calfw.el
index 0681140..ef3f7e2 100644
--- a/elpa/excorporate-0.6.0/excorporate-calfw.el
+++ b/elpa/excorporate-0.6.0/excorporate-calfw.el
@@ -28,12 +28,9 @@
(require 'excorporate)
(eval-when-compile (require 'cl))
-(defun exco-calfw-maybe-extra-argument (server-version)
- "If SERVER-VERSION is less than 2013 then return an empty list.
-Otherwise return a list with one nil element."
- (if (< ( string-to-number (substring server-version 8 12)) 2013)
- '()
- '(nil)))
+(defun exco-calfw-server-year (server-version)
+ "Extract the year as an integer from SERVER-VERSION"
+ (string-to-number (substring server-version 8 12)))
(defun exco-calfw-get-meetings-for-day (month day year callback)
"Return the meetings for the specified day.
@@ -63,8 +60,11 @@ CALLBACK with two arguments, IDENTIFIER and RESPONSE."
(ParentFolderIds
(DistinguishedFolderId (Id . "calendar"))))
;; Empty arguments.
- nil nil nil nil nil ,@(exco-calfw-maybe-extra-argument
- (exco-server-version nil)))
+ ,@(let ((year (exco-calfw-server-year (exco-server-version nil))))
+ (cond
+ ((<= year 2007) '(nil nil nil nil))
+ ((< year 2013) '(nil nil nil nil nil))
+ (t '(nil nil nil nil nil nil)))))
callback)))
(defun exco-calfw-show-day (month day year)
diff --git a/elpa/excorporate-0.6.0/excorporate.el b/elpa/excorporate-0.6.0/excorporate.el
index 8318aab..2db2a54 100644
--- a/elpa/excorporate-0.6.0/excorporate.el
+++ b/elpa/excorporate-0.6.0/excorporate.el
@@ -658,8 +658,8 @@ The mail address to use for autodiscovery."
:tag "Prompt for Exchange mail address to use for autodiscovery" nil)
(string :tag "Exchange mail address to use for autodiscovery")
(cons :tag "Skip autodiscovery"
- (string :tag "Exchange mail address")
- (string :tag "Exchange Web Services URL"))))
+ (string :tag "Exchange mail address, e.g you@example.com")
+ (string :tag "Exchange Web Services URL e.g. https://example.com/Exchange.asmx"))))
;;;###autoload
(defun excorporate ()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment