Slightly better suggestion of how to set load-path (#2888)

This commit is contained in:
Perry Smith 2022-12-31 06:28:53 -06:00 committed by GitHub
parent 11affb52e2
commit db837da019
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 9 additions and 9 deletions

View File

@ -147,7 +147,7 @@ manual.
Here is the basic setup to add to your `user-init-file` (`.emacs`): Here is the basic setup to add to your `user-init-file` (`.emacs`):
```lisp ```lisp
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(unless (require 'el-get nil 'noerror) (unless (require 'el-get nil 'noerror)
(with-current-buffer (with-current-buffer
@ -163,7 +163,7 @@ Here is the basic setup to add to your `user-init-file` (`.emacs`):
### Alternative Basic Setup with Installation via MELPA ### Alternative Basic Setup with Installation via MELPA
```elisp ```elisp
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(unless (require 'el-get nil 'noerror) (unless (require 'el-get nil 'noerror)
(require 'package) (require 'package)
@ -291,7 +291,7 @@ tries to initialize the package.
```lisp ```lisp
;; Basic setup ;; Basic setup
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(unless (require 'el-get nil 'noerror) (unless (require 'el-get nil 'noerror)
(with-current-buffer (with-current-buffer

View File

@ -384,7 +384,7 @@ File: el-get.info, Node: Basic Setup, Next: The el-get function, Up: Setup
You can then arrange to have El-Get part of your setup, so that at next You can then arrange to have El-Get part of your setup, so that at next
emacs startup the installed packages are initialized. emacs startup the installed packages are initialized.
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(unless (require 'el-get nil t) (unless (require 'el-get nil t)
(with-current-buffer (with-current-buffer
@ -459,7 +459,7 @@ documentation is usable as-is. It is recommended that you not store the
El-Get tree in git, however; to prevent this, so you can add a pattern El-Get tree in git, however; to prevent this, so you can add a pattern
`/el-get' to `.emacs.d/.gitignore'. `/el-get' to `.emacs.d/.gitignore'.
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(require 'el-get) (require 'el-get)
;; local sources ;; local sources
@ -506,7 +506,7 @@ directory, and still enjoy a truly portable emacs configuration.
specify a local source to install. With this macro, nothing other than specify a local source to install. With this macro, nothing other than
specified packages is installed. specified packages is installed.
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(require 'el-get) (require 'el-get)
;; packages from recipe files ;; packages from recipe files

View File

@ -385,7 +385,7 @@ You can then arrange to have El-Get part of your setup, so that at
next emacs startup the installed packages are initialized. next emacs startup the installed packages are initialized.
@example @example
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(unless (require 'el-get nil t) (unless (require 'el-get nil t)
(with-current-buffer (with-current-buffer
@ -458,7 +458,7 @@ however; to prevent this, so you can add a pattern @code{/el-get} to
@code{.emacs.d/.gitignore}. @code{.emacs.d/.gitignore}.
@example @example
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(require 'el-get) (require 'el-get)
;; local sources ;; local sources
@ -510,7 +510,7 @@ specify a local source to install. With this macro, nothing other
than specified packages is installed. than specified packages is installed.
@example @example
(add-to-list 'load-path "~/.emacs.d/el-get/el-get") (add-to-list 'load-path (expand-file-name "el-get/el-get" user-emacs-directory))
(require 'el-get) (require 'el-get)
;; packages from recipe files ;; packages from recipe files