From: Hongyi Zhao <hongyi.zhao@gmail.com>
To: Emanuel Berg <moasenwood@zoho.eu>,
help-gnu-emacs <help-gnu-emacs@gnu.org>
Subject: Re: Set the HOME environment variable in Emacs package debug script instead of using it on command line.
Date: Tue, 26 Oct 2021 17:57:10 +0800 [thread overview]
Message-ID: <CAGP6POKzE0EMJ2OdVZ9ae1xhsDczNMGuP68OFimRGf55V4vCLw@mail.gmail.com> (raw)
In-Reply-To: <87h7d4ml5j.fsf@zoho.eu>
On Tue, Oct 26, 2021 at 1:05 PM Emanuel Berg via Users list for the
GNU Emacs text editor <help-gnu-emacs@gnu.org> wrote:
>
> Hongyi Zhao wrote:
>
> > I want to set the HOME environment variable in the lisp
> > code, so it will not disturb the system environment
> > variable settings.
>
> Don't understand (don't want to :)) but there is `setenv' FYI.
I've set the new HOME with the following method, but it doesn't get
the same testing result as reported here [1]:
#!/usr/bin/env bash
:; env myhome=$(dirname $(dirname $(realpath -e $0)))
proxychains-ng-socks5 /usr/local/bin/emacs -Q --load $(realpath -e $0)
-- "$@"; exit
(setenv "HOME" (substitute-in-file-name "${myhome}"))
;;Bootstrap straight
(defvar bootstrap-version)
(let ((bootstrap-file
(expand-file-name "straight/repos/straight.el/bootstrap.el"
user-emacs-directory))
(bootstrap-version 5))
(unless (file-exists-p bootstrap-file)
(with-current-buffer
(url-retrieve-synchronously
"https://raw.githubusercontent.com/raxod502/straight.el/develop/install.el"
'silent 'inhibit-cookies)
(goto-char (point-max))
(eval-print-last-sexp)))
(load bootstrap-file nil 'nomessage))
(straight-use-package 'use-package)
(setq straight-use-package-by-default t)
(use-package company
:demand t
:hook
(after-init . global-company-mode))
[1] https://github.com/company-mode/company-mode/discussions/1248#discussioncomment-1535692
next prev parent reply other threads:[~2021-10-26 9:57 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-26 2:01 Set the HOME environment variable in Emacs package debug script instead of using it on command line Hongyi Zhao
2021-10-26 5:04 ` Emanuel Berg via Users list for the GNU Emacs text editor
2021-10-26 9:57 ` Hongyi Zhao [this message]
2021-10-26 11:25 ` Emanuel Berg via Users list for the GNU Emacs text editor
2021-10-26 12:37 ` Hongyi Zhao
2021-10-26 12:49 ` Emanuel Berg via Users list for the GNU Emacs text editor
2021-10-26 13:39 ` Hongyi Zhao
2021-10-26 13:58 ` Emanuel Berg via Users list for the GNU Emacs text editor
2021-10-27 0:40 ` Hongyi Zhao
2021-10-27 0:52 ` Emanuel Berg via Users list for the GNU Emacs text editor
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CAGP6POKzE0EMJ2OdVZ9ae1xhsDczNMGuP68OFimRGf55V4vCLw@mail.gmail.com \
--to=hongyi.zhao@gmail.com \
--cc=help-gnu-emacs@gnu.org \
--cc=moasenwood@zoho.eu \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.