emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Achim Gratz <Stromeko@nexgo.de>
To: emacs-orgmode@gnu.org
Subject: Re: [PATCH] org version under Windows 7
Date: Wed, 11 Jul 2012 19:43:36 +0200	[thread overview]
Message-ID: <87ehoiyz07.fsf@Rainer.invalid> (raw)
In-Reply-To: 1342018996.75825.YahooMailNeo@web29804.mail.ird.yahoo.com

[-- Attachment #1: Type: text/plain, Size: 684 bytes --]

Giovanni Ridolfi writes:
> 1   I downloaded from http://orgmode.org/w/org-mode.git
>     the last git snapshot (c75120aa71257604....)

Jason, it would be quite useful if the Git snapshots would include both
org-install.el and org-version.el — is it perhaps possible to sneak a
"make autoloads" into the script that creates those?

Bastien, here's a patch that allows to override the version strings more
easily.  You'd then eval this form:

(let ((org-fake-release "7.8.11")
      (org-fake-git-version "7.8.11-fake"))
  (org-make-autoloads))

either from the scratch buffer or the command line.  I'll update org
hacks with the instructions when you have installed the patch.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: override version strings --]
[-- Type: text/x-patch, Size: 2993 bytes --]

From 5805109804bc55ef6bf079366dfd24fb928377c3 Mon Sep 17 00:00:00 2001
From: Achim Gratz <Stromeko@Stromeko.DE>
Date: Wed, 11 Jul 2012 19:32:33 +0200
Subject: [PATCH]  Let the user override the version strings produced in
 org-fixup.

* UTILITIES/org-fixup.el (org-fixup): Let the user override the
  version strings produced in org-fixup whith strings stored in
  org-fake-release and org-fake-git-version.  Skip loading them from a
  pre-existing org-version.el or trying to determine them from git in
  this case.  This is predominantly useful if Git is not available,
  but the user wants to install from a Git tarball which is missing a
  pre-configured org-version.el file.
---
 UTILITIES/org-fixup.el |   37 +++++++++++++++++++++----------------
 1 file changed, 21 insertions(+), 16 deletions(-)

diff --git a/UTILITIES/org-fixup.el b/UTILITIES/org-fixup.el
index 1e03801..20613d2 100644
--- a/UTILITIES/org-fixup.el
+++ b/UTILITIES/org-fixup.el
@@ -140,22 +140,27 @@ (defmacro org-fixup ()
 	 (dirgit (concat dirorg ".git/" ))
 	 (org-version "N/A-fixup")
 	 (org-git-version "N/A-fixup !!check installation!!"))
-    (if (load (concat dirlisp "org-version.el") 'noerror 'nomessage 'nosuffix)
-	(setq org-version     (org-release)
-	      org-git-version (org-git-version))
-      (when (and (file-exists-p dirgit)
-		 (executable-find "git"))
-	(unwind-protect
-	    (progn
-	      (cd dirorg)
-	      (let ((git6 (substring (shell-command-to-string "git describe --abbrev=6 HEAD") 0 -1))
-		    (git0 (substring (shell-command-to-string "git describe --abbrev=0 HEAD") 0 -1))
-		    (gitd (string-match "\\S-" (shell-command-to-string "git status -uno --porcelain"))))
-		(setq org-git-version (concat git6 (when gitd ".dirty")))
-		(if (string-match "^release_" git0)
-		    (setq org-version (substring git0 8))
-		  (setq org-version git0))))
-	  (cd origin))))
+    (if (and (boundp 'org-fake-release)     (stringp org-fake-release)
+	     (boundp 'org-fake-git-version) (stringp org-fake-git-version))
+	(setq org-version     org-fake-release
+	      org-git-version org-fake-git-version)
+      (if (load (concat dirlisp "org-version.el") 'noerror 'nomessage 'nosuffix)
+	  (setq org-version     (org-release)
+		org-git-version (org-git-version))
+	(when (and (file-exists-p dirgit)
+		   (executable-find "git"))
+	  (unwind-protect
+	      (progn
+		(cd dirorg)
+		(let ((git6 (substring (shell-command-to-string "git describe --abbrev=6 HEAD") 0 -1))
+		      (git0 (substring (shell-command-to-string "git describe --abbrev=0 HEAD") 0 -1))
+		      (gitd (string-match "\\S-"
+					  (shell-command-to-string "git status -uno --porcelain"))))
+		  (setq org-git-version (concat git6 (when gitd ".dirty")))
+		  (if (string-match "^release_" git0)
+		      (setq org-version (substring git0 8))
+		    (setq org-version git0))))
+	  (cd origin)))))
     `(progn
        (defun org-release () ,org-version)
        (defun org-git-version () ,org-git-version)
-- 
1.7.10.4


[-- Attachment #3: Type: text/plain, Size: 201 bytes --]



Regards,
Achim.
-- 
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

Waldorf MIDI Implementation & additional documentation:
http://Synth.Stromeko.net/Downloads.html#WaldorfDocs

  parent reply	other threads:[~2012-07-11 17:44 UTC|newest]

Thread overview: 37+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-11 15:03 org version under Windows 7 Giovanni Ridolfi
2012-07-11 16:46 ` Achim Gratz
2012-07-11 17:43 ` Achim Gratz [this message]
2012-07-11 20:21   ` [PATCH] " Bastien
2012-07-11 21:15     ` Achim Gratz
2012-07-12  6:31       ` Bastien
2012-07-12  8:30       ` Giovanni Ridolfi
2012-07-12 13:24         ` Achim Gratz
2012-07-24 15:23   ` Bastien
2012-07-25  7:52     ` Giovanni Ridolfi
2012-07-26 12:50       ` Bastien
2012-07-26 18:49     ` Achim Gratz
2012-07-31 16:36       ` Bastien
2013-01-02 22:22 ` Babel related bug in elpa version 20121231 Robert Horn
2013-01-04  2:16   ` Robert Horn
2013-01-04 15:23     ` Bastien
2013-01-04 21:27   ` Achim Gratz
2013-01-05  0:10     ` Robert Horn
2013-01-05  7:07       ` Achim Gratz
2013-01-05 11:07         ` Bastien
2013-01-05 11:45           ` Achim Gratz
2013-01-05 12:33             ` Bastien
2013-01-05 13:40               ` Achim Gratz
2013-01-05 14:00                 ` Bastien
2013-01-05 16:40           ` Robert Horn
2013-01-05 16:55             ` Achim Gratz
2013-01-05 18:51               ` Eric Schulte
2013-01-05 19:07                 ` Achim Gratz
2013-01-05 19:28                   ` Eric Schulte
2013-01-05 20:39                     ` Achim Gratz
2013-01-05 23:29                       ` Eric Schulte
     [not found]                 ` <CAGoVJLFRky2wOZUkyAVTp3E9eXnsYoetAckWKJs1MKyqQHUCFA@mail.gmail.com>
2013-01-05 20:55                   ` Fwd: " Stelian Iancu
2013-01-05 21:16                     ` Eric Schulte
2013-01-05 21:10                 ` Robert Horn
2013-01-05 22:14                   ` Tom Davey
2013-01-05 23:30                     ` Eric Schulte
2013-01-06 20:21                       ` Stelian Iancu

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=87ehoiyz07.fsf@Rainer.invalid \
    --to=stromeko@nexgo.de \
    --cc=emacs-orgmode@gnu.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).