From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id +LUOIJnBV2DhbwAA0tVLHw (envelope-from ) for ; Sun, 21 Mar 2021 21:58:49 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2 with LMTPS id QMzNG5nBV2AlFQAAB5/wlQ (envelope-from ) for ; Sun, 21 Mar 2021 21:58:49 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 7F232209A9 for ; Sun, 21 Mar 2021 22:58:48 +0100 (CET) Received: from localhost ([::1]:43312 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lO65v-0008Nr-Lf for larch@yhetil.org; Sun, 21 Mar 2021 17:58:47 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:49506) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lO65P-0008Nj-Fl for emacs-orgmode@gnu.org; Sun, 21 Mar 2021 17:58:15 -0400 Received: from mail-pg1-x530.google.com ([2607:f8b0:4864:20::530]:41838) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lO65N-0000ag-Vu for emacs-orgmode@gnu.org; Sun, 21 Mar 2021 17:58:15 -0400 Received: by mail-pg1-x530.google.com with SMTP id m7so7370086pgj.8 for ; Sun, 21 Mar 2021 14:58:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=references:user-agent:from:to:subject:date:in-reply-to:message-id :mime-version; bh=eRbaeW5VZelKLiayfIeaVuZeKAFIOJA8dIpLntKw7+4=; b=nfenkBHTwtGXyHIL+jn3fEpXHx7n1vDyvlTBYdJPxWbf3TVUizehcercqfKL5LJZm4 uumuuivCpqB+gy5aXUTIZGt74mZrZbi6qCGVYMW+zMb0NuAQ+mEs69b0jsVref7k6UHH Dy20s8TMl+9DAY7oTY8tzV41XvYTd5Ad9KLF+M127cLtbuN2BI9w0jBQ4RxjOIIvJ6g7 Fd5WMKyuRqcJzlrys9jF2sYFxz3V2otvjeFxea0QLL0+id+kleWOW4aEurwhI0ppd9Io DP4wIIDUPIkAIcyedLCp7bpUgmAQJEUvBcFDn/8uuBU0ebX40f6e5R+y8bDYWNI9ir/g iQdA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:references:user-agent:from:to:subject:date :in-reply-to:message-id:mime-version; bh=eRbaeW5VZelKLiayfIeaVuZeKAFIOJA8dIpLntKw7+4=; b=YuDX1hc9tATqzbQc8o5h+XLcc1lDKJopesakAt5SciIxk2adNnjnZmqDkssCfLQv/w rpxBWTCADoNqr6xVEOwYoXhkaIKBeSPXsHO35U39heQt6pV39zaBHEoe+Wuh4MVR3Jlg qtLwQWlEblSPaDdd8kFRpzBMJ78XiXRhsDaESt5UPeXfzQX1d8QSGM6B3vweILEwbxLJ Cl1/7PEuOsxL0YpmX7y8rMMPPyb8z9Ry5bqW8/449TBVI1bdOagTV1AQv+cHI/Y5z65H loN+XOtWI60CKVvvI+QZMxbZ7q+HRBJm/Eb/UHwZJTf8mlY0Y4Rl+GaeUoKSNlidiVz5 Fu/A== X-Gm-Message-State: AOAM532DtxjtwcTdjnzusA5tV7bGDZ9ER5q2/HGhOlu0rOKXVdbVaxfc Qit4P0klP4Ggj9K30oNClNALdQhxOHU= X-Google-Smtp-Source: ABdhPJwfwXjpiDEqp9CvJ5eAOD0SNdQ14vVQ7PN58R62QecojDlExlGVJF4O/elEg4hV9veELRYAyA== X-Received: by 2002:a63:d58:: with SMTP id 24mr19993823pgn.171.1616363892502; Sun, 21 Mar 2021 14:58:12 -0700 (PDT) Received: from tim-desktop (106-69-118-82.dyn.iinet.net.au. [106.69.118.82]) by smtp.gmail.com with ESMTPSA id y29sm11808605pfp.206.2021.03.21.14.58.10 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 21 Mar 2021 14:58:12 -0700 (PDT) References: <705757.1616348671@apollo2.minshall.org> User-agent: mu4e 1.5.11; emacs 27.2 From: Tim Cross To: emacs-orgmode@gnu.org Subject: Re: trivial software engineering'ish question: switching org's Date: Mon, 22 Mar 2021 08:35:00 +1100 In-reply-to: <705757.1616348671@apollo2.minshall.org> Message-ID: <87mtuwkw3y.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2607:f8b0:4864:20::530; envelope-from=theophilusx@gmail.com; helo=mail-pg1-x530.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Migadu-Flow: FLOW_IN ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1616363928; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=eRbaeW5VZelKLiayfIeaVuZeKAFIOJA8dIpLntKw7+4=; b=UG8S5854Zz4KWq+E4rySRrpLsdgDCCchn1NAUZGnfQm/PB1AyCOfM2DdcCL6M+khKsbOPq Xlb+GLZRtQmBarFwOIk7ORTjDZ8LPGmtxnIUpssTDQX9emXRGGyaKqnwxAazOvHXpgQ2JN ND7yybRbHh/YbdbdlgNvONEqjKU2gGDCs1+AKGHtqysh0D9/iypVPOYvATgSLLRJJ1AWwh 8q4jmozAUGGuRD6mznbAaqnKHJsCZTHgVI9BjnsUl+bnthrTBFp2stfzGwZXoM7VANu281 yKNW/x+1+bJp+V5DFx17cq+GFtkfhhoMzF0zhoHom5Ck97na6H0gs8sbElBhTg== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1616363928; a=rsa-sha256; cv=none; b=nW5Qrvc1wmpPXEzeesCaHRcOJERibTNG7j+PDHfpjKRn7MBnUxF8v9CF5mMXRVwUv7S7uq KWOUW6H4o4yN+W2GfCuPvw7/x5mOjwtb3+jHQGouSmHrIZ/npEcaiH45X3zvSHBCQkHcIE L/f8gJznvmec4UOTvV0jK9nzJJ0acSCUy1F7iO9mAfLRHBAodwN8vEVKRGnvTzm9Z1wTYV 0NiaDjEDuRh96fghc0jUAjXgn67CGQD6XQlzR5imte9e6J/B+Tkoo7EeqgmjCjCOYy1v1m KjcriA+UpZrlcT6szoBkEcy2z8cp2PfSyx5IAchlzoMQEt9+4hpdUh9osnDHCQ== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=nfenkBHT; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Spam-Score: -3.12 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20161025 header.b=nfenkBHT; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Migadu-Queue-Id: 7F232209A9 X-Spam-Score: -3.12 X-Migadu-Scanner: scn0.migadu.com X-TUID: Mt2wpUMtGznB Greg Minshall writes: > hi. i occasionally want to switch from the org package to a git > version, then back again. and, i want to avoid the dread "mixed > installation". > > i'm wondering is there a way people do this other than simply > installing/deleting the package version? > As I understand it, the critical part is when Emacs compiles the org files to get the *.elc versions. Provided you do not have any org functionality loaded during that compilation process, everything should be OK. The 'mixed' versions problem arises because you go to compile a different version and Emacs includes definitions already loaded from another version, generating *.elc files with mixed versions. Once org is compiled, the critical part is having the org version you want show up first in the load-path, so the problem becomes one of just managing the load-path entries appropriately. You could just ensure the version you want is higher in the load-path or you could go the 'paranoid' route and have code which removes the version you don't want from the load-path. In the past, what I've done is have the git version of org in a specific directory which I build with a separate process from the command line using the make recipes in the repository - essentially just configuring and running make. I then have some code in my init.el file which sets that version at the start of my load-path when I want to run it and which I comment out when I just want to run the version installed by package.el. I also use the use-package macro to load my org configuration and have two different blocks for that - one loading the git repo version and one loading the org-plus-contrib version I normally use. I just comment out the one I don't want to use. I probably could write some elisp to automate this, but to be honest, I switch between org versions so rarely, commenting/uncommenting parts of my init.el file is easy enough. I don't do any of that at the moment as I've not needed to run from the git repo since I switched to spacemacs and the spacemacs setup already has the necessary workflow to ensure new versions of org are compiled in a clean environment. Have not yet thought about how I will need to add git based org when using spacemacs. Suspect All I'll need to do is adjust the load-path as part of the init to reference the git sources before any org functionality is loaded. -- Tim Cross