]> git.eshelyaron.com Git - emacs.git/commitdiff
Allow :pin to accept a symbol
authorJohn Wiegley <johnw@newartisans.com>
Mon, 16 Mar 2015 07:48:13 +0000 (02:48 -0500)
committerJohn Wiegley <johnw@newartisans.com>
Mon, 16 Mar 2015 07:48:13 +0000 (02:48 -0500)
lisp/use-package/use-package.el

index b843725eccbbd752c9e44b05f586f2e68943cdf0..638a16ee992a456d35f0d4213fb282a488b0a73c 100644 (file)
@@ -304,9 +304,12 @@ the user specified.")
           (:pin
            (use-package-only-one (symbol-name head) args
              (lambda (label arg)
-               (if (stringp arg)
-                   arg
-                 (use-package-error ":pin wants an archive name (a string)")))))
+               (cond
+                ((stringp arg) arg)
+                ((symbolp arg) (symbol-name arg))
+                (t
+                 (use-package-error
+                  ":pin wants an archive name (a string)"))))))
 
           (_ (use-package-error (format "Unrecognized keyword: %s" head)))))
        (use-package-normalize-plist name-symbol tail)))))