Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can I update all packages by bash script? #16133

Closed
JaydenFish opened this issue Aug 22, 2023 · 2 comments
Closed

Can I update all packages by bash script? #16133

JaydenFish opened this issue Aug 22, 2023 · 2 comments

Comments

@JaydenFish
Copy link

I want to update packages and spacemacs by bash script. click update button is troublesome.
I can update spacemacs by git pull --rebase. But how to update packages by bash script?

@real-or-random
Copy link
Contributor

real-or-random commented Aug 24, 2023

The button is bound to the function configuration-layer/update-packages, which you can also run via SPC f e U.

If you want to run it from the command line, you should try emacs --funcall=configuration-layer/update-packages. (Or emacs --eval=<expr> if you need a more flexible alternative that takes arbitrary expressions, see man emacs.) I haven't tried this, and I'm not sure if this works. Updating packages is a somewhat involved operation, so something is at odds when you call it from the command line. But it's worth a try, and I agree that it could be convenient after git pull.

@McPhale
Copy link

McPhale commented Aug 24, 2023

I was able to do that by following this stack exchange post: https://emacs.stackexchange.com/a/45923

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants