emacsorphanage/req-package

Support for package-selected-packages

bbigras opened this issue · 9 comments

Do you think req-package could fill up package-selected-packages so that running package-autoremovewould not remove the packages we use?

Do you think req-package could fill up package-selected-packages

This is what it already does (at least for me). req-package is a wrapper around use-package, which uses package.el under the hood. As for Emacs 25.1, when package-selected-packages was introduced, calling (package-install package) automatically adds the package to package-selected-packages.

Hi. Yes, it's supposed to work the same way as if you install a package from package.el

Also el-get-install for el-get

I assumed it wasn't the case since package-autoremove wants to remove a lot of my packages.

I have (req-package rust-mode) in my config but package-autoremove wants to remove it. Is there a way to rebuild the package-selected-packages variable or should I delete my ~/.emacs.d and let req-package re-install everything?

Could you try to just remove rust-mode and ~/.emacs.d/elpa/archives dir, please? It should fetch contents and reinstall rust-mode. If it doesn't help, we need to investigate this thing.

To remove rust-mode I also had to remove racer and cargo. I also removed the archives dir. rust-mode was reinstalled automatically but package-selected-packages wasn't updated.

I can modify package-selected-packages inside emacs and it get saved custom.el.

My config and custom.el are on a dropbox share. I use it on 3 computers.

my package-selected-packages

'(package-selected-packages
   (quote
    (bar-cursor mwim counsel counsel-projectile yasnippet company-go company hydra org-autolist org-bullets guide-key undo-tree color-theme-sanityinc-tomorrow async org-plus-contrib smooth-scrolling req-package paradox)))

my config

(req-package cargo)
(req-package rust-mode)
(req-package racer
  :require company
  :config (progn
            (add-hook 'rust-mode-hook #'racer-mode)
            (add-hook 'racer-mode-hook #'eldoc-mode)
            (add-hook 'racer-mode-hook #'company-mode)))

Can't reproduce at current dev version. Do you still have this issue ? @BrunoQC

I think I still have the issue with the latest version from melpa.

If I run package-autoremove go-mode and projectile would be removed even if I have the following. I tested with a new .emacs.d directory and a new custom file.

(req-package go-mode
  :require projectile)

package-selected-packages only contains (paradox req-package).

Package providers system has been removed and this should not be an issue anymore as long as you're using v.1.1 and :ensure from use-package
https://github.com/edvorg/req-package/tree/v1.1