all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* How to reload an updated library?
@ 2015-03-01 23:22 Tory S. Anderson
  2015-03-02  1:38 ` bernardo
  2015-03-03 20:34 ` Vaidheeswaran C
  0 siblings, 2 replies; 10+ messages in thread
From: Tory S. Anderson @ 2015-03-01 23:22 UTC (permalink / raw
  To: Emacs Help List

In this case, I'm talking about the Helm package. I follow it on git and sometimes will `git pull` to update it, then can make it. But the only way I know to implement the new changes in emacs is to restart emacs. I tried evaluate-buffer on one of the main library files, but it didn't seem to do the trick. Restarting emacs is a pain if I have many ongoing projects; how can I implement the updates to the package without restarting emacs? 



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

* Re: How to reload an updated library?
       [not found] <mailman.1086.1425252146.31049.help-gnu-emacs@gnu.org>
@ 2015-03-01 23:44 ` Emanuel Berg
  2015-03-02  1:50   ` Tory S. Anderson
  0 siblings, 1 reply; 10+ messages in thread
From: Emanuel Berg @ 2015-03-01 23:44 UTC (permalink / raw
  To: help-gnu-emacs

torys.anderson@gmail.com (Tory S. Anderson) writes:

> In this case, I'm talking about the Helm package. I
> follow it on git and sometimes will `git pull` to
> update it, then can make it. But the only way I know
> to implement the new changes in emacs is to restart
> emacs. I tried evaluate-buffer on one of the main
> library files, but it didn't seem to do the trick.
> Restarting emacs is a pain if I have many ongoing
> projects; how can I implement the updates to the
> package without restarting emacs?

With "library", do you mean something more advanced
than just an Elisp (.el) file which is usually what is
meant?

Such are loaded with <drumroll> `load' - either
`load-file' (input the library file) or `load-library'
(ditto name). With `load-library' you will get the
.elc compiled version rather than the .el source if
both are available.

-- 
underground experts united


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

* Re: How to reload an updated library?
  2015-03-01 23:22 Tory S. Anderson
@ 2015-03-02  1:38 ` bernardo
  2015-03-03 20:34 ` Vaidheeswaran C
  1 sibling, 0 replies; 10+ messages in thread
From: bernardo @ 2015-03-02  1:38 UTC (permalink / raw
  To: Emacs Help List


> In this case, I'm talking about the Helm package. I follow it on git and
> sometimes will `git pull` to update it, then can make it. But the only way
> I know to implement the new changes in emacs is to restart emacs. I tried
> evaluate-buffer on one of the main library files, but it didn't seem to do
> the trick. Restarting emacs is a pain if I have many ongoing projects; how
> can I implement the updates to the package without restarting emacs?
>
>

haven't tried it, but (unload-feature '....) followed by (require '....)
might be worth a shot




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

* Re: How to reload an updated library?
  2015-03-01 23:44 ` How to reload an updated library? Emanuel Berg
@ 2015-03-02  1:50   ` Tory S. Anderson
  2015-03-02  2:08     ` Alexis
       [not found]     ` <mailman.1093.1425262142.31049.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 10+ messages in thread
From: Tory S. Anderson @ 2015-03-02  1:50 UTC (permalink / raw
  To: Emacs Help List, Emanuel Berg

I've never been quite clear in emacs on the meanings of library, package, extension... I think I mean package, such as what you download from `m-x list-packages`: in this case, a whole program like Helm which includes many .el files. 

Emanuel Berg <embe8573@student.uu.se> writes:

> torys.anderson@gmail.com (Tory S. Anderson) writes:
>
>> In this case, I'm talking about the Helm package. I
>> follow it on git and sometimes will `git pull` to
>> update it, then can make it. But the only way I know
>> to implement the new changes in emacs is to restart
>> emacs. I tried evaluate-buffer on one of the main
>> library files, but it didn't seem to do the trick.
>> Restarting emacs is a pain if I have many ongoing
>> projects; how can I implement the updates to the
>> package without restarting emacs?
>
> With "library", do you mean something more advanced
> than just an Elisp (.el) file which is usually what is
> meant?
>
> Such are loaded with <drumroll> `load' - either
> `load-file' (input the library file) or `load-library'
> (ditto name). With `load-library' you will get the
> .elc compiled version rather than the .el source if
> both are available.



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

* Re: How to reload an updated library?
  2015-03-02  1:50   ` Tory S. Anderson
@ 2015-03-02  2:08     ` Alexis
  2015-03-02  2:22       ` Tory S. Anderson
       [not found]     ` <mailman.1093.1425262142.31049.help-gnu-emacs@gnu.org>
  1 sibling, 1 reply; 10+ messages in thread
From: Alexis @ 2015-03-02  2:08 UTC (permalink / raw
  To: help-gnu-emacs


On 2015-03-02T12:50:28+1100, Tory S. Anderson said:

 TSA> I've never been quite clear in emacs on the meanings of 
 library, TSA> package, extension... I think I mean package, such 
 as what you TSA> download from `m-x list-packages`: in this case, 
 a whole program TSA> like Helm which includes many .el files.

In my experience, in the context of Emacs, a 'package' is 
something that is downloaded from one of the ELPAs (Emacs Lisp 
Package Archives) - GNU ELPA, MELPA, MELPA-Stable, Marmalade 
etc. If you're installing Helm by cloning the Git repo and loading 
it manually, you're actually not making use of the Emacs package 
system. i would recommend installing Helm from one of the ELPAs, 
and then using the upgrade functionality of Emacs' package 
system[1] - when you upgrade a package, it will usually (again, in 
my experience) get reloaded once the local package has been 
updated.

Things that aren't actually available for processing by 
`package.el` i would refer to as 'extensions' or 'libraries', 
regardless of how many ELisp source files they include.


Alexis.

[1] E.g. by doing M-x package-list-packages, then typing U to mark 
all upgradeable packages, then typing x to start the upgrade 
process.



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

* Re: How to reload an updated library?
       [not found]     ` <mailman.1093.1425262142.31049.help-gnu-emacs@gnu.org>
@ 2015-03-02  2:18       ` Joost Kremers
  2015-03-02  2:40         ` Alexis
  0 siblings, 1 reply; 10+ messages in thread
From: Joost Kremers @ 2015-03-02  2:18 UTC (permalink / raw
  To: help-gnu-emacs

Alexis wrote:
> [1] E.g. by doing M-x package-list-packages, then typing U to mark 
> all upgradeable packages, then typing x to start the upgrade 
> process.

Actually, this doesn't guarantee that the upgraded packages are loaded
properly. I've found that there are cases where restarting Emacs is an
unfortunate necessity.

Helm is in fact one of these cases:

https://github.com/emacs-helm/helm#install-from-emacs-packaging-system


-- 
Joost Kremers                                   joostkremers@fastmail.fm
Selbst in die Unterwelt dringt durch Spalten Licht
EN:SiS(9)


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

* Re: How to reload an updated library?
  2015-03-02  2:08     ` Alexis
@ 2015-03-02  2:22       ` Tory S. Anderson
  2015-03-02  2:35         ` Alexis
  0 siblings, 1 reply; 10+ messages in thread
From: Tory S. Anderson @ 2015-03-02  2:22 UTC (permalink / raw
  To: Alexis; +Cc: help-gnu-emacs

You're right; usually I rely on Elpa/MELPA, but I believe (correct me if I'm wrong) that even MELPA takes a day to update, hence my use of the git repo. 

Alexis <flexibeast@gmail.com> writes:

> On 2015-03-02T12:50:28+1100, Tory S. Anderson said:
>
> TSA> I've never been quite clear in emacs on the meanings of library, TSA> package, extension... I think I mean package, such as what you TSA> download from `m-x list-packages`: in this case, a whole program TSA> like Helm which includes many .el files.
>
> In my experience, in the context of Emacs, a 'package' is something that is downloaded from one of the ELPAs (Emacs Lisp Package Archives) - GNU ELPA, MELPA, MELPA-Stable, Marmalade etc. If you're installing Helm by cloning the Git repo and loading it manually, you're actually not making use of the Emacs package system. i would recommend installing Helm from one of the ELPAs, and then using the upgrade functionality of Emacs' package system[1] - when you upgrade a package, it will usually (again, in my experience) get reloaded once the local package has been updated.
>
> Things that aren't actually available for processing by `package.el` i would refer to as 'extensions' or 'libraries', regardless of how many ELisp source files they include.
>
>
> Alexis.
>
> [1] E.g. by doing M-x package-list-packages, then typing U to mark all upgradeable packages, then typing x to start the upgrade process.



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

* Re: How to reload an updated library?
  2015-03-02  2:22       ` Tory S. Anderson
@ 2015-03-02  2:35         ` Alexis
  0 siblings, 0 replies; 10+ messages in thread
From: Alexis @ 2015-03-02  2:35 UTC (permalink / raw
  To: help-gnu-emacs


On 2015-03-02T13:22:02+1100, Tory S. Anderson said:

 TSA> You're right; usually I rely on Elpa/MELPA, but I believe 
 TSA> (correct me if I'm wrong) that even MELPA takes a day to 
 update, TSA> hence my use of the git repo.

No, MELPA rebuilds modified packages roughly every hour (or two at 
most). So when i push changes to the GitHub repo for any one of 
the Emacs packages i maintain, a new version of the relevant 
package is usually available for download within 1-2 hours 
(sometimes much less, if i've pushed the changes minutes before a 
scheduled MELPA build).


Alexis.



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

* Re: How to reload an updated library?
  2015-03-02  2:18       ` Joost Kremers
@ 2015-03-02  2:40         ` Alexis
  0 siblings, 0 replies; 10+ messages in thread
From: Alexis @ 2015-03-02  2:40 UTC (permalink / raw
  To: help-gnu-emacs


On 2015-03-02T13:18:36+1100, Joost Kremers said:

 JK> Alexis wrote:

 >> [1] E.g. by doing M-x package-list-packages, then typing U to 
 >> mark all upgradeable packages, then typing x to start the 
 >> upgrade process.

 JK> Actually, this doesn't guarantee that the upgraded packages 
 are JK> loaded properly. I've found that there are cases where 
 restarting JK> Emacs is an unfortunate necessity.

 JK> Helm is in fact one of these cases:

 JK> 
 https://github.com/emacs-helm/helm#install-from-emacs-packaging-system

True! i typically don't need Helm updates that urgently, and 
restart either Emacs or my system on a regular basis, so i don't 
particular notice this issue.

Nevertheless, i would still suggest that people try to use the 
package system as much as possible, and only work around it when 
absolutely necessary (such as needing Helm updates as rapidly as 
possible).


Alexis.



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

* Re: How to reload an updated library?
  2015-03-01 23:22 Tory S. Anderson
  2015-03-02  1:38 ` bernardo
@ 2015-03-03 20:34 ` Vaidheeswaran C
  1 sibling, 0 replies; 10+ messages in thread
From: Vaidheeswaran C @ 2015-03-03 20:34 UTC (permalink / raw
  To: help-gnu-emacs

On Monday 02 March 2015 04:52 AM, Tory S. Anderson wrote:

> In this case, I'm talking about the Helm package. I follow it on git
> and sometimes will `git pull` to update it, then can make it. But
> the only way I know to implement the new changes in emacs is to
> restart emacs. I tried evaluate-buffer on one of the main library
> files, but it didn't seem to do the trick. Restarting emacs is a
> pain if I have many ongoing projects; how can I implement the
> updates to the package without restarting emacs?

For single file libraries use,

M-x load-library file.el

M-x load-library file.elc





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

end of thread, other threads:[~2015-03-03 20:34 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <mailman.1086.1425252146.31049.help-gnu-emacs@gnu.org>
2015-03-01 23:44 ` How to reload an updated library? Emanuel Berg
2015-03-02  1:50   ` Tory S. Anderson
2015-03-02  2:08     ` Alexis
2015-03-02  2:22       ` Tory S. Anderson
2015-03-02  2:35         ` Alexis
     [not found]     ` <mailman.1093.1425262142.31049.help-gnu-emacs@gnu.org>
2015-03-02  2:18       ` Joost Kremers
2015-03-02  2:40         ` Alexis
2015-03-01 23:22 Tory S. Anderson
2015-03-02  1:38 ` bernardo
2015-03-03 20:34 ` Vaidheeswaran C

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.