all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Setting package archives
@ 2021-05-25 16:08 pauline-galea
  2021-05-25 20:29 ` Philip Kaludercic
  0 siblings, 1 reply; 2+ messages in thread
From: pauline-galea @ 2021-05-25 16:08 UTC (permalink / raw)
  To: Help Gnu Emacs

How can I set package-archives in emacs

I am using the following

(defun gungadin-locate-archives ()
  "Installs package archives."
  (require 'package)
  (add-to-list 'package-archives
     '( ("gnu" . "https://elpa.gnu.org/packages/")
        ("melpa-stable" . "https://melpa.org/packages/")
        ("org" . "https://orgmode.org/elpa/")) )
   (package-initialize) )






^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Setting package archives
  2021-05-25 16:08 Setting package archives pauline-galea
@ 2021-05-25 20:29 ` Philip Kaludercic
  0 siblings, 0 replies; 2+ messages in thread
From: Philip Kaludercic @ 2021-05-25 20:29 UTC (permalink / raw)
  To: pauline-galea; +Cc: Help Gnu Emacs

pauline-galea@gmx.com writes:

> How can I set package-archives in emacs
>
> I am using the following
>
> (defun gungadin-locate-archives ()
>   "Installs package archives."
>   (require 'package)
>   (add-to-list 'package-archives
>      '( ("gnu" . "https://elpa.gnu.org/packages/")
>         ("melpa-stable" . "https://melpa.org/packages/")
>         ("org" . "https://orgmode.org/elpa/")) )
>    (package-initialize) )

You are adding a list *into* a list, instead of appending each of the
items *onto* the list. 

What you probably want to do is 

(add-to-list 'package-archives '("gnu" . "https://elpa.gnu.org/packages/"))
(add-to-list 'package-archives '("melpa-stable" . "https://melpa.org/packages/"))
(add-to-list 'package-archives '("org" . "https://orgmode.org/elpa/"))

where the first `add-to-list' won't be necessary, because GNU ELPA is
configured by default.

-- 
	Philip K.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-05-25 20:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-05-25 16:08 Setting package archives pauline-galea
2021-05-25 20:29 ` Philip Kaludercic

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.