Re: Cream slow to start up

2006-12-14 Thread Gary Johnson
On 2006-12-14, Yakov Lerner <[EMAIL PROTECTED]> wrote:
> On 12/14/06, Gary Johnson <[EMAIL PROTECTED]> wrote:
> > On 2006-12-14, Yakov Lerner <[EMAIL PROTECTED]> wrote:
> > > On 12/13/06, Gary Johnson <[EMAIL PROTECTED]> wrote:
> > > > On 2006-12-03, Yakov Lerner <[EMAIL PROTECTED]> wrote:
> > > >
> > > > > You can try 'gvim.exe -V20/tmp/log' to identity points of slowness.
> > > > > You might need timestamps in the logfile for that. To add timestamps,
> > > > > you can try to redirect the logfile to the named pipe and the to
> > > > > utility which adds  timestamps.
> > > >
> > > > What utility that adds timestamps?
> > >
> > > I don't know if you can call the [1] and [2] below 'utilities', but
> > > they copy standard input to standard output, adding
> > > the timestamp to microsecond resolution to each line.
> > > [1] is in perl, [2] is in C. Worksforme.
> >
> > Thanks!  timestamp.c works great, but I had to download the
> > Time::HiRes module for timestamp.pl and now I can't get timestamp.pl
> > to find it.  (I don't use Perl very often.)  I put the module here:
> >
> > /home/garyjohn/lib/perl/Time/HiRes.pm
> >
> > and added this line,
> >
> > use lib ("/home/garyjohn/lib/perl");
> >
> > to timestamp.pl, but when I use timestamp.pl I get this message:
> >
> > Can't locate loadable object for module Time::HiRes in @INC (@INC 
> > contains: /home/garyjohn/lib/perl /usr/perl5/5.00503/sun4-solaris 
> > /usr/perl5/5.00503 /usr/perl5/site_perl/5.005/sun4-solaris 
> > /usr/perl5/site_perl/5.005 .) at ./timestamp.pl line 7
> > BEGIN failed--compilation aborted at ./timestamp.pl line 7.
> >
> > It would be nice to have the Perl version working so that I don't
> > have to compile the C version for every OS I use, but it's not a big
> > deal if the solution doesn't jump out at you.
> 
> Time::HiRes is standard with perl 5.8. It can be easier to
> install newer perl.

Thanks for the suggestion.  I found that we have perl 5.8.6 on this 
system already, but it's in /opt/TWWfsw/bin/perl rather than 
/usr/bin/perl, so I just changed the first line of timestamp.pl to

#!/usr/bin/env perl

and now it works fine, too.

Regards,
Gary

-- 
Gary Johnson | Agilent Technologies
[EMAIL PROTECTED] | Wireless Division
 | Spokane, Washington, USA


Re: Cream slow to start up

2006-12-14 Thread Yakov Lerner

On 12/14/06, Gary Johnson <[EMAIL PROTECTED]> wrote:

On 2006-12-14, Yakov Lerner <[EMAIL PROTECTED]> wrote:
> On 12/13/06, Gary Johnson <[EMAIL PROTECTED]> wrote:
> > On 2006-12-03, Yakov Lerner <[EMAIL PROTECTED]> wrote:
> >
> > > You can try 'gvim.exe -V20/tmp/log' to identity points of slowness.
> > > You might need timestamps in the logfile for that. To add timestamps,
> > > you can try to redirect the logfile to the named pipe and the to
> > > utility which adds  timestamps.
> >
> > What utility that adds timestamps?
>
> I don't know if you can call the [1] and [2] below 'utilities', but
> they copy standard input to standard output, adding
> the timestamp to microsecond resolution to each line.
> [1] is in perl, [2] is in C. Worksforme.

Thanks!  timestamp.c works great, but I had to download the
Time::HiRes module for timestamp.pl and now I can't get timestamp.pl
to find it.  (I don't use Perl very often.)  I put the module here:

/home/garyjohn/lib/perl/Time/HiRes.pm

and added this line,

use lib ("/home/garyjohn/lib/perl");

to timestamp.pl, but when I use timestamp.pl I get this message:

Can't locate loadable object for module Time::HiRes in @INC (@INC contains: 
/home/garyjohn/lib/perl /usr/perl5/5.00503/sun4-solaris /usr/perl5/5.00503 
/usr/perl5/site_perl/5.005/sun4-solaris /usr/perl5/site_perl/5.005 .) at 
./timestamp.pl line 7
BEGIN failed--compilation aborted at ./timestamp.pl line 7.

It would be nice to have the Perl version working so that I don't
have to compile the C version for every OS I use, but it's not a big
deal if the solution doesn't jump out at you.


Time::HiRes is standard with perl 5.8. It can be easier to
install newer perl.
Yakov


Re: Cream slow to start up

2006-12-14 Thread Gary Johnson
On 2006-12-14, Yakov Lerner <[EMAIL PROTECTED]> wrote:
> On 12/13/06, Gary Johnson <[EMAIL PROTECTED]> wrote:
> > On 2006-12-03, Yakov Lerner <[EMAIL PROTECTED]> wrote:
> >
> > > You can try 'gvim.exe -V20/tmp/log' to identity points of slowness.
> > > You might need timestamps in the logfile for that. To add timestamps,
> > > you can try to redirect the logfile to the named pipe and the to
> > > utility which adds  timestamps.
> >
> > What utility that adds timestamps?
> 
> I don't know if you can call the [1] and [2] below 'utilities', but
> they copy standard input to standard output, adding
> the timestamp to microsecond resolution to each line.
> [1] is in perl, [2] is in C. Worksforme.

Thanks!  timestamp.c works great, but I had to download the 
Time::HiRes module for timestamp.pl and now I can't get timestamp.pl 
to find it.  (I don't use Perl very often.)  I put the module here:

/home/garyjohn/lib/perl/Time/HiRes.pm

and added this line,

use lib ("/home/garyjohn/lib/perl");

to timestamp.pl, but when I use timestamp.pl I get this message:

Can't locate loadable object for module Time::HiRes in @INC (@INC contains: 
/home/garyjohn/lib/perl /usr/perl5/5.00503/sun4-solaris /usr/perl5/5.00503 
/usr/perl5/site_perl/5.005/sun4-solaris /usr/perl5/site_perl/5.005 .) at 
./timestamp.pl line 7
BEGIN failed--compilation aborted at ./timestamp.pl line 7.

It would be nice to have the Perl version working so that I don't
have to compile the C version for every OS I use, but it's not a big
deal if the solution doesn't jump out at you.

Thanks again,
Gary

-- 
Gary Johnson | Agilent Technologies
[EMAIL PROTECTED] | Wireless Division
 | Spokane, Washington, USA


Re: Cream slow to start up

2006-12-13 Thread Yakov Lerner

On 12/13/06, Gary Johnson <[EMAIL PROTECTED]> wrote:

On 2006-12-03, Yakov Lerner <[EMAIL PROTECTED]> wrote:

> You can try 'gvim.exe -V20/tmp/log' to identity points of slowness.
> You might need timestamps in the logfile for that. To add timestamps,
> you can try to redirect the logfile to the named pipe and the to
> utility which adds  timestamps.

What utility that adds timestamps?


I don't know if you can call the [1] and [2] below 'utilities', but
they copy standard input to standard output, adding
the timestamp to microsecond resolution to each line.
[1] is in perl, [2] is in C. Worksforme.

Good luck,
Yakov

[1] - timestamp.pl ---
#!/usr/bin/perl -w
# timestamp.pl  --  copy standard input to standard output, adding
#   timestamps with microsecond resolution.

use POSIX qw(strftime);
use Time::HiRes qw(gettimeofday);

my ($seconds, $microseconds, $formatted_time );

while() {
   ($seconds, $microseconds) = gettimeofday;
   $formatted_time = strftime( "%H:%M:%S", localtime($seconds));
   printf "%s.%06d %s",  $formatted_time, $microseconds, $_;
}

[2] timestamp.c
--
/* timestamp.c  - copy standard input to standard output, adding */
/*timestamps with microsecond resolution */

#include 
#include 
#include 

char *timestamp(char *buf, int max, time_t _time) {
   struct tm tm_;

   localtime_r(&_time, &tm_);
   strftime(buf, max, "%H:%M:%S", &tm_);
   return buf;
}


int main() {
   char buf[1024];
   char timebuf[30];
   struct timeval tv;

   while(fgets(buf, sizeof(buf), stdin) != NULL) {
   gettimeofday(&tv, NULL);
   printf("%s.%06ld %s",
  timestamp(timebuf, sizeof(timebuf), tv.tv_sec),
(long)tv.tv_usec, buf);
   }
   return 0;
}
---


Re: Cream slow to start up

2006-12-13 Thread Gary Johnson
On 2006-12-03, Yakov Lerner <[EMAIL PROTECTED]> wrote:

> You can try 'gvim.exe -V20/tmp/log' to identity points of slowness.
> You might need timestamps in the logfile for that. To add timestamps,
> you can try to redirect the logfile to the named pipe and the to
> utility which adds  timestamps.

What utility that adds timestamps?

Regards,
Gary

-- 
Gary Johnson | Agilent Technologies
[EMAIL PROTECTED] | Wireless Division
 | Spokane, Washington, USA


Re: Cream slow to start up

2006-12-03 Thread Georg Dahn

Hi!

I love gvim and use it at work on a Linux system with no connection to 
the outside world. My coworkers laugh at copy-paste cycles that involve 
ya i" and  code completion, but I 
consistently code-compile-debug faster than they can using eclipse.


In Vim on Windows systems you can copy with Ctrl-Insert, paste with 
Shift-Insert, and cut with Ctrl-Delete even without sourcing mswin.vim 
or using Cream. I use this very much. It is just a matter of ones habit 
if one uses Ctrl-C, Ctrl-V, and Ctrl-X or the other shortcuts, which you 
can use everywhere in Windows. Maybe this or something similar works on 
Linux Systems, too.


I thought OK, let's setup vim to be more user friendly so I can do 
advocacy. This led me to using cream.


Cream is a very fine configuration of Vim, it is more or less an editor 
of its own. I don't use it, but I have installed it for some people who 
did not like the native behavior of Vim but want to have its features.


If you are doing fine with the native behavior of Vim (and you told us, 
that you are very quick with it), why don't you stay with it? You have 
to work with it efficiently, not the others. But it is a matter of 
taste, I got used to the native behavior of Vim before I found Cream and 
 do not want to learn a new Editor, since I am rather efficient with 
Vim. And my configuration files do exactly what I want them to...


Best wishes,
Georg





Send instant messages to your online friends http://uk.messenger.yahoo.com 


Re: Cream slow to start up

2006-12-02 Thread Steve Hall
On Fri, 2006-12-01 at 15:24 +0200, Matti Picus wrote:
>
[...]
> 
> I thought OK, let's setup vim to be more user friendly so I can do
> advocacy. This led me to using cream.

Cream has it's own lists (http://cream.sf.net/about.html), for the
record. This list is quite tolerant, but I'd ask that you move this
discussion there so we avoid taking advantage of it.

> I installed it
> (http://prdownloads.sourceforge.net/cream/cream-0-38-gvim-7-0-152.exe)
> on a windows computer to test, but found cream and its installation
> of vim both very slow to start up, on the order of 10s of seconds,
> about the same time as a network timeout. Is this reasonable?

No, it should only add 2-3 seconds to normal gVim, maybe one or two
more the first startup.

> Is there some kind of "call home" in the startup files?

No.

> A clean installation of vim 7.0 from source on the same machine does
> not have this problem.

Cream is added to Vim, so it will never be as fast. It's overhead
includes retained preferences, a different interface, add-ons,
additional features, etc. But 10 seconds sounds like there is a
problem, perhaps your discovered $HOME location is remote?

Join the cream-general list and I'll help you sort it out.


-- 
Steve Hall  [ digitect dancingpaper com ]
:: Cream... usability for Vim
::   http://cream.sourceforge.net




Re: Cream slow to start up

2006-12-02 Thread Yakov Lerner

On 12/1/06, Matti Picus <[EMAIL PROTECTED]> wrote:

I love gvim and use it at work on a Linux system with no connection to
the outside world. My coworkers laugh at copy-paste cycles that involve
ya i" and  code completion, but I
consistently code-compile-debug faster than they can using eclipse.


I thought OK, let's setup vim to be more user friendly so I can do
advocacy. This led me to using cream.

I installed it (
http://prdownloads.sourceforge.net/cream/cream-0-38-gvim-7-0-152.exe )
on a windows computer to test, but found cream and its installation of
vim both very slow to start up, on the order of 10s of seconds, about
the same time as a network timeout. Is this reasonable? Is there some
kind of "call home" in the startup files? A clean installation of vim
7.0 from source on the same machine does not have this problem.


You can try 'gvim.exe -V20/tmp/log' to identity points of slowness.
You might need timestamps in the logfile for that. To add timestamps,
you can try to redirect the logfile to the named pipe and the to
utility which adds  timestamps.

Yakov


Cream slow to start up

2006-12-02 Thread Matti Picus
I love gvim and use it at work on a Linux system with no connection to 
the outside world. My coworkers laugh at copy-paste cycles that involve 
ya i" and  code completion, but I 
consistently code-compile-debug faster than they can using eclipse.



I thought OK, let's setup vim to be more user friendly so I can do 
advocacy. This led me to using cream.


I installed it ( 
http://prdownloads.sourceforge.net/cream/cream-0-38-gvim-7-0-152.exe ) 
on a windows computer to test, but found cream and its installation of 
vim both very slow to start up, on the order of 10s of seconds, about 
the same time as a network timeout. Is this reasonable? Is there some 
kind of "call home" in the startup files? A clean installation of vim 
7.0 from source on the same machine does not have this problem.