From: "Sebastien Vauban" <sva-news-D0wtAvR13HarG/iDocfnWg@public.gmane.org>
To: emacs-orgmode-mXXj517/zsQ@public.gmane.org
Cc: Bastien <bzg-mXXj517/zsQ@public.gmane.org>
Subject: Invalid function: org-with-silent-modifications
Date: Thu, 26 Sep 2013 14:22:24 +0200 [thread overview]
Message-ID: <86fvsrixhb.fsf@somewhere.org> (raw)
Hello,
Trying to provide batch Emacs/Org scripts to colleagues, I must ensure that
they have Org 8.
I wrote the following code so that users which have a default (Cygwin) Emacs
24.3.1 (with the default Org 7.9.3f) are proposed an upgrade through the
`package' manager:
--8<---------------cut here---------------start------------->8---
(require 'package)
(add-to-list 'package-archives '("org" . "http://orgmode.org/elpa/"))
(package-initialize)
;; version info
(let ((org-dir (file-name-directory (locate-library "org"))))
(message "Org mode version %s (org @ %s)" (org-version) org-dir))
(unless (string-match "^8" (org-version))
(message "This version of Org mode is no longer supported")
(if (yes-or-no-p (format "Install package `%s'? " 'org))
(ignore-errors
(package-install 'org))
(setq debug-on-error nil)
(error "Please upgrade to 8 or later")))
--8<---------------cut here---------------end--------------->8---
Problem experienced by colleagues: "Invalid function:
org-with-silent-modifications".
Looking on the web, I find a post [1] where Bastien tells:
When installing from ELPA, please do so from a fresh Emacs session where no
Org function has been called.
That wasn't the case in the above code, as I first had to call `org-version' to
check for their current version, then install from ELPA if they don't have an
Org 8...
So,
- Is there a way to unload Org before installing from ELPA? (= workaround)
or better:
- Is there a way to fix the problem? (= solution)
Best regards,
Seb
[1] http://comments.gmane.org/gmane.emacs.orgmode/70880
--
Sebastien Vauban
reply other threads:[~2013-09-26 12:22 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86fvsrixhb.fsf@somewhere.org \
--to=sva-news-d0wtavr13harg/idocfnwg@public.gmane.org \
--cc=bzg-mXXj517/zsQ@public.gmane.org \
--cc=emacs-orgmode-mXXj517/zsQ@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).