unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* optional packages on startup?
@ 2011-07-26  6:42 Jai Dayal
  2011-07-26  6:51 ` Jambunathan K
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Jai Dayal @ 2011-07-26  6:42 UTC (permalink / raw)
  To: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 384 bytes --]

Hi,
  In emacs, I have a lot of things that load up (cscopes, cedet, ecb).
Since I have to ssh into a proxy, and then into the main server, there's a
bit of latency for emacs to start up.

Is there an easy way to say 'emacs simple filename.cpp' and if simple is
present, it skips over some number of packages?  Doing emacs filename.cpp,
however, would load all packages.

Thanks!
Jai

[-- Attachment #2: Type: text/html, Size: 424 bytes --]

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

* Re: optional packages on startup?
  2011-07-26  6:42 optional packages on startup? Jai Dayal
@ 2011-07-26  6:51 ` Jambunathan K
  2011-07-26  6:56   ` Jambunathan K
  2011-08-05  8:10   ` Oleksandr Gavenko
  2011-07-26  6:52 ` Andreas Röhler
  2011-07-26  8:33 ` Peter Dyballa
  2 siblings, 2 replies; 10+ messages in thread
From: Jambunathan K @ 2011-07-26  6:51 UTC (permalink / raw)
  To: Jai Dayal; +Cc: help-gnu-emacs


> Hi,
>   In emacs, I have a lot of things that load up (cscopes, cedet,
> ecb).  Since I have to ssh into a proxy, and then into the main
> server, there's a bit of latency for emacs to start up.

Never do a (require 'package) - either for uncompiled or compiled
packages.

Always compile the installed packages - autoloads ensures that the
packages are loaded on demand. 

There lots of other things that you could do but the above two steps
will ensure visible improvements.

> Is there an easy way to say 'emacs simple filename.cpp' and if simple
> is present, it skips over some number of packages?  Doing emacs
> filename.cpp, however, would load all packages.
>
> Thanks!
> Jai
>
>

-- 



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

* Re: optional packages on startup?
  2011-07-26  6:42 optional packages on startup? Jai Dayal
  2011-07-26  6:51 ` Jambunathan K
@ 2011-07-26  6:52 ` Andreas Röhler
  2011-07-26  8:33 ` Peter Dyballa
  2 siblings, 0 replies; 10+ messages in thread
From: Andreas Röhler @ 2011-07-26  6:52 UTC (permalink / raw)
  To: help-gnu-emacs

Am 26.07.2011 08:42, schrieb Jai Dayal:
> Hi,
>    In emacs, I have a lot of things that load up (cscopes, cedet, ecb).
> Since I have to ssh into a proxy, and then into the main server, there's a
> bit of latency for emacs to start up.
>
> Is there an easy way to say 'emacs simple filename.cpp' and if simple is
> present, it skips over some number of packages?  Doing emacs filename.cpp,
> however, would load all packages.
>
> Thanks!
> Jai
>

Hi,

what about write into your init-file

(if CONDITION
    load this
   load that)

(file-readable-p) might a suitable condition IIUC

Andreas



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

* Re: optional packages on startup?
  2011-07-26  6:51 ` Jambunathan K
@ 2011-07-26  6:56   ` Jambunathan K
  2011-08-05  8:10   ` Oleksandr Gavenko
  1 sibling, 0 replies; 10+ messages in thread
From: Jambunathan K @ 2011-07-26  6:56 UTC (permalink / raw)
  To: Jai Dayal; +Cc: help-gnu-emacs

Jambunathan K <kjambunathan@gmail.com> writes:

>> Hi,
>>   In emacs, I have a lot of things that load up (cscopes, cedet,
>> ecb).  Since I have to ssh into a proxy, and then into the main
>> server, there's a bit of latency for emacs to start up.
>
> Never do a (require 'package) - either for uncompiled or compiled
> packages.
>
> Always compile the installed packages - autoloads ensures that the
> packages are loaded on demand. 

You need to require the autoload file though.

> There lots of other things that you could do but the above two steps
> will ensure visible improvements.

Jambunathan K.



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

* Re: optional packages on startup?
  2011-07-26  6:42 optional packages on startup? Jai Dayal
  2011-07-26  6:51 ` Jambunathan K
  2011-07-26  6:52 ` Andreas Röhler
@ 2011-07-26  8:33 ` Peter Dyballa
  2011-07-26 12:13   ` Perry Smith
  2 siblings, 1 reply; 10+ messages in thread
From: Peter Dyballa @ 2011-07-26  8:33 UTC (permalink / raw)
  To: Jai Dayal; +Cc: help-gnu-emacs


Am 26.07.2011 um 08:42 schrieb Jai Dayal:

> Since I have to ssh into a proxy, and then into the main server, there's a
> bit of latency for emacs to start up.

Create a SIMPLE (or basic) init file and launch GNU Emacs as 'emacs -l SIMPLE.el'. A shell alias can help to reduce typing.

--
Greetings

  Pete

Basic, n.:
	A programming language. Related to certain social diseases in that those who have it will not admit it in polite company.




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

* Re: optional packages on startup?
  2011-07-26  8:33 ` Peter Dyballa
@ 2011-07-26 12:13   ` Perry Smith
       [not found]     ` <CAMJ-YiSmDHLRpLV+bLrMuP3kdx8zQnoSsv_RLTz2DFuDc4xAww@mail.gmail.com>
  0 siblings, 1 reply; 10+ messages in thread
From: Perry Smith @ 2011-07-26 12:13 UTC (permalink / raw)
  To: Peter Dyballa; +Cc: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 694 bytes --]


On Jul 26, 2011, at 3:33 AM, Peter Dyballa wrote:

> 
> Am 26.07.2011 um 08:42 schrieb Jai Dayal:
> 
>> Since I have to ssh into a proxy, and then into the main server, there's a
>> bit of latency for emacs to start up.
> 
> Create a SIMPLE (or basic) init file and launch GNU Emacs as 'emacs -l SIMPLE.el'. A shell alias can help to reduce typing.

My suggestion is to leave a "server" emacs running and then just attach to it when you ssh over.  See emacsclient for more details (or ask this list).

> 
> Basic, n.:
> 	A programming language. Related to certain social diseases in that those who have it will not admit it in polite company.


Java, n.:
  The new Basic


[-- Attachment #2: Type: text/html, Size: 1305 bytes --]

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

* Fwd: optional packages on startup?
       [not found]       ` <CAMJ-YiR7=i+HX1Pr+1x7p4rzMOPnUSBuo9cqxVYfFZSsqtrtmg@mail.gmail.com>
@ 2011-07-29 16:46         ` Jai Dayal
  2011-07-29 16:54           ` Perry Smith
  2011-07-29 20:47           ` Peter Dyballa
  0 siblings, 2 replies; 10+ messages in thread
From: Jai Dayal @ 2011-07-29 16:46 UTC (permalink / raw)
  To: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 2144 bytes --]

Basically, it's still loading CEDET.  Any idea why?


---------- Forwarded message ----------
From: Jai Dayal <dayalsoap@gmail.com>
Date: Fri, Jul 29, 2011 at 10:46 AM
Subject: Re: optional packages on startup?
To: Perry Smith <pedzsan@gmail.com>




On Wed, Jul 27, 2011 at 2:59 PM, Jai Dayal <dayalsoap@gmail.com> wrote:

> I've done this, but it still pulls things like cedet...
>
> Here's the messages buffer.
>
> ("emacs" "-l" ".simple.el")
> Loading /ascldap/users/jdayal/cedet-1.0/common/cedet.el (source)...
> Setting up CEDET packages...
> Cannot open load file: cogre-loaddefs
> Cannot open load file: contrib-loaddefs
> Setting up CEDET packages...done
> Loading /ascldap/users/jdayal/cedet-1.0/common/cedet.el (source)...done
> For information about GNU Emacs and the GNU system, type C-h C-a.
>
>
> here's .simple.el
>
> ;;
> .emacs
>
> (global-set-key "\C-xg" 'goto-line)
>
> ;; turn on font-lock
> mode
>
> (when (fboundp
> 'global-font-lock-mode)
>
>   (global-font-lock-mode t))
>
>
> (setq c-default-style
> "stroustrup"
>
>       c-basic-offset 4)
>
> ;; enable visual feedback on
> selections
>
> ;(setq transient-mark-mode
> t)
>
>
> ;; default to better frame
> titles
>
> (setq
> frame-title-format
>
>       (concat  "%b - emacs@" (system-name)))
>
> ;; default to unified
> diffs
>
> (setq diff-switches "-u")
>
>
>
>
> On Tue, Jul 26, 2011 at 6:13 AM, Perry Smith <pedzsan@gmail.com> wrote:
>
>>
>> On Jul 26, 2011, at 3:33 AM, Peter Dyballa wrote:
>>
>>
>> Am 26.07.2011 um 08:42 schrieb Jai Dayal:
>>
>> Since I have to ssh into a proxy, and then into the main server, there's a
>>
>> bit of latency for emacs to start up.
>>
>>
>> Create a SIMPLE (or basic) init file and launch GNU Emacs as 'emacs -l
>> SIMPLE.el'. A shell alias can help to reduce typing.
>>
>>
>> My suggestion is to leave a "server" emacs running and then just attach to
>> it when you ssh over.  See emacsclient for more details (or ask this list).
>>
>>
>> Basic, n.:
>> A programming language. Related to certain social diseases in that those
>> who have it will not admit it in polite company.
>>
>>
>> Java, n.:
>>   The new Basic
>>
>>
>

[-- Attachment #2: Type: text/html, Size: 5440 bytes --]

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

* Re: optional packages on startup?
  2011-07-29 16:46         ` Fwd: " Jai Dayal
@ 2011-07-29 16:54           ` Perry Smith
  2011-07-29 20:47           ` Peter Dyballa
  1 sibling, 0 replies; 10+ messages in thread
From: Perry Smith @ 2011-07-29 16:54 UTC (permalink / raw)
  To: Jai Dayal; +Cc: help-gnu-emacs

[-- Attachment #1: Type: text/plain, Size: 4478 bytes --]

Hi,

I don't use CEDET.  If you do connect more than once to the same emacs server and it continues to pull in cedet, I would look at your mode hooks first to see what they are doing.  Usually it should use "require /  provide" rather than "load".

Hopefully a more cedet savvy person will reply too.

Good luck,
pedz


On Jul 29, 2011, at 11:46 AM, Jai Dayal wrote:

> 
> 
> Basically, it's still loading CEDET.  Any idea why?
> 
> 
> ---------- Forwarded message ----------
> From: Jai Dayal <dayalsoap@gmail.com>
> Date: Fri, Jul 29, 2011 at 10:46 AM
> Subject: Re: optional packages on startup?
> To: Perry Smith <pedzsan@gmail.com>
> 
> 
> 
> 
> On Wed, Jul 27, 2011 at 2:59 PM, Jai Dayal <dayalsoap@gmail.com> wrote:
> I've done this, but it still pulls things like cedet...
> 
> Here's the messages buffer.
> 
> ("emacs" "-l" ".simple.el")
> Loading /ascldap/users/jdayal/cedet-1.0/common/cedet.el (source)...
> Setting up CEDET packages...
> Cannot open load file: cogre-loaddefs
> Cannot open load file: contrib-loaddefs
> Setting up CEDET packages...done
> Loading /ascldap/users/jdayal/cedet-1.0/common/cedet.el (source)...done
> For information about GNU Emacs and the GNU system, type C-h C-a.
> 
> 
> here's .simple.el
> 
> ;; .emacs                                                                                                                                                                                                                                    
> (global-set-key "\C-xg" 'goto-line)
> 
> ;; turn on font-lock mode                                                                                                                                                                                                                    
> (when (fboundp 'global-font-lock-mode)                                                                                                                                                                                                       
>   (global-font-lock-mode t))
> 
> 
> (setq c-default-style "stroustrup"                                                                                                                                                                                                           
>       c-basic-offset 4)
> 
> ;; enable visual feedback on selections                                                                                                                                                                                                      
> ;(setq transient-mark-mode t)                                                                                                                                                                                                                
> 
> ;; default to better frame titles                                                                                                                                                                                                            
> (setq frame-title-format                                                                                                                                                                                                                     
>       (concat  "%b - emacs@" (system-name)))
> 
> ;; default to unified diffs                                                                                                                                                                                                                  
> (setq diff-switches "-u")
> 
> 
> 
> 
> On Tue, Jul 26, 2011 at 6:13 AM, Perry Smith <pedzsan@gmail.com> wrote:
> 
> On Jul 26, 2011, at 3:33 AM, Peter Dyballa wrote:
> 
>> 
>> Am 26.07.2011 um 08:42 schrieb Jai Dayal:
>> 
>>> Since I have to ssh into a proxy, and then into the main server, there's a
>>> bit of latency for emacs to start up.
>> 
>> Create a SIMPLE (or basic) init file and launch GNU Emacs as 'emacs -l SIMPLE.el'. A shell alias can help to reduce typing.
> 
> My suggestion is to leave a "server" emacs running and then just attach to it when you ssh over.  See emacsclient for more details (or ask this list).
> 
>> 
>> Basic, n.:
>> 	A programming language. Related to certain social diseases in that those who have it will not admit it in polite company.
> 
> 
> Java, n.:
>   The new Basic
> 
> 
> 
> 


[-- Attachment #2: Type: text/html, Size: 15530 bytes --]

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

* Re: optional packages on startup?
  2011-07-29 16:46         ` Fwd: " Jai Dayal
  2011-07-29 16:54           ` Perry Smith
@ 2011-07-29 20:47           ` Peter Dyballa
  1 sibling, 0 replies; 10+ messages in thread
From: Peter Dyballa @ 2011-07-29 20:47 UTC (permalink / raw)
  To: Jai Dayal; +Cc: help-gnu-emacs


Am 29.07.2011 um 18:46 schrieb Jai Dayal:

> Basically, it's still loading CEDET.  Any idea why?

Maybe the site-run-file dictates loading of CEDET...

--
Greetings

  Pete

Progress (n.): Process through which USENET evolved from smart people in front of dumb terminals to dumb people in front of smart terminals.




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

* Re: optional packages on startup?
  2011-07-26  6:51 ` Jambunathan K
  2011-07-26  6:56   ` Jambunathan K
@ 2011-08-05  8:10   ` Oleksandr Gavenko
  1 sibling, 0 replies; 10+ messages in thread
From: Oleksandr Gavenko @ 2011-08-05  8:10 UTC (permalink / raw)
  To: help-gnu-emacs

26.07.2011 9:51, Jambunathan K пишет:
>
>> Hi,
>>    In emacs, I have a lot of things that load up (cscopes, cedet,
>> ecb).  Since I have to ssh into a proxy, and then into the main
>> server, there's a bit of latency for emacs to start up.
>
> Never do a (require 'package) - either for uncompiled or compiled
> packages.
>
I use '(desktop-save-mode 1)', so even I do not put 'require' it is
too long wait when Emacs loading as I have many files opened with
several different file types (for all of them loaded appropriated
major mode)...

Some times I use code like this:

(eval-after-load 'grep
   '(progn
      (add-to-list 'grep-find-ignored-directories "build" t)
      (add-to-list 'grep-find-ignored-directories "dist" t)
      (add-to-list 'grep-find-ignored-directories "lib" t)

      (when (boundp 'grep-find-ignored-files)
        (add-to-list 'grep-find-ignored-files "*TAGS")
        (add-to-list 'grep-find-ignored-files "GPATH")
        )
      ))

to prevent from loading grep.el at sturtup.




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

end of thread, other threads:[~2011-08-05  8:10 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-26  6:42 optional packages on startup? Jai Dayal
2011-07-26  6:51 ` Jambunathan K
2011-07-26  6:56   ` Jambunathan K
2011-08-05  8:10   ` Oleksandr Gavenko
2011-07-26  6:52 ` Andreas Röhler
2011-07-26  8:33 ` Peter Dyballa
2011-07-26 12:13   ` Perry Smith
     [not found]     ` <CAMJ-YiSmDHLRpLV+bLrMuP3kdx8zQnoSsv_RLTz2DFuDc4xAww@mail.gmail.com>
     [not found]       ` <CAMJ-YiR7=i+HX1Pr+1x7p4rzMOPnUSBuo9cqxVYfFZSsqtrtmg@mail.gmail.com>
2011-07-29 16:46         ` Fwd: " Jai Dayal
2011-07-29 16:54           ` Perry Smith
2011-07-29 20:47           ` Peter Dyballa

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).