Re: Problems with terminal doesn't display visual elements properly

2011-03-20 Thread Diego Queiroz
On 18 March 2011 06:12, Andy Koppe wrote:
>
> On 17 March 2011 22:09, Diego Queiroz wrote:
> > Hello.
> >
> > I need some help.
> > My terminal started with a very strange behavior today.
> > Many programs are not displaying correctly and I don't know why.
> >
> > I uploaded this picture: http://img851.imageshack.us/i/screenshotfc.png/
> > The two windows at the top are displaying the "nano" and "top"
> > programs using putty.
> > The two windows at the bottom are displaying the same programs using
> > cygwin, respectively.
> >
> > As you can see, the visual of the applications is different, and that's not 
> > all.
> > I'm really not able to work with these applications because of this
> > problem. Actually, any visual enhancement is not working properly.
> > Even grep with --color option isn't working correctly.
> >
> > In the image, both programs are connected to the same server thru ssh,
> > so IMO the problem is not related with server configuration or any
> > tool specific setting.
> > The problem also occurs when using cygwin in the local machine.
> >
> > I'm almost sure the problem is related with the dos emulator, but I
> > don't have an idea whats wrong.
> > The problem started when I did the last cygwin update (but I also
> > updated many programs in the machine together, so I don't know if
> > cygwin caused this).
>
> What's the server? Are you connecting with cygwin ssh (i.e.
> /usr/bin/ssh)? What's the TERM setting on the server? It should be
> 'cygwin'. or, if the server doesn't know that, 'vt100' should do.
>
> You might also want to try mintty (where TERM should be 'xterm').
>
> Andy

Hello Andy.
Thanks for your reply.

But it doesn't really matter.

Quote:
"IMO the problem is not related with server configuration or any tool
specific setting. The problem also occurs when using cygwin in the
local machine."

I mean, the same problem also occurs when I am connected with no
server at all (just the local installation of cygwin).


Regards,
---
Diego Queiroz

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



[ANNOUNCEMENT] Updated: mercurial-1.8.1-1 -- Python based distributed version control (DVCS)

2011-03-20 Thread Jari Aalto

PACKAGE DESCRIPTION
===

Homepage: http://mercurial.selenic.com
License : GPL

Distributed, efficient Python based source control system. Mercurial is
designed for efficient handling of very large distributed projects.

CHANGES SINCE LAST RELEASE
==

See http://mercurial.selenic.com/wiki/WhatsNew

INSTALL OR UPGRADE NOTES


Standard Cygwin install. For more information, see
http://mercurial.selenic.com/wiki/UpgradeNotes

CYGWIN INSTALLATION INFORMATION
===

To install this package, click on the "Install Cygwin now" link on the
 web page. This downloads setup.exe to your
system. Then, run setup and answer all of the questions. You'll find
the package listed in the "All" category. After installation, read the
documentation at directories:

/usr/share/doc//*
/usr/share/doc/Cygwin/.README

If you have questions or comments, please send them to the Cygwin
mailing list at .

CYGWIN-ANNOUNCE UNSUBSCRIBE INFO


This message has been sent to cygwin-announce list.

If you want to unsubscribe from the mailing list, look at the
"List-Unsubscribe: " tag in the email header of this message. Send
email to the address specified there. It will be in the format:

cygwin-announce-unsubscribe-you=yourdomain.com(at)cygwin.com

More information on unsubscribing can be found:

http://sources.redhat.com/lists.html#unsubscribe-simple

Please read *all* of the information on unsubscribing that is available
starting at the above URL.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



[ANNOUNCEMENT] Updated: bzr 2.3.1-1 -- Python based distributed version control (DVCS)

2011-03-20 Thread Jari Aalto

PACKAGE DESCRIPTION
===

Home page: http://bazaar.canonical.com
License  : GPL (Bzr is part of GNU project)

Distributed version control that is used in projects like managing
Ubuntu packages  and it is one of the funded
projects of Canonical.

- Uses one .bzr directory at the top of the tree
- The user interface is simple and familiar to people with experience
  from CVS or Subversion.
- Offers a choice between centralized and decentralized/diconnected work.
- Strong security. History can be GPG-signed to protect against
  man-in-the-middle attacks, bad mirrors, server intrusion or data
  corruption.

CHANGES SINCE LAST RELEASE
==

https://launchpad.net/bzr/+announcements
http://doc.bazaar.canonical.com/bzr.dev/en/release-notes/index.html
http://doc.bazaar.canonical.com/en/

INSTALL OR UPGRADE NOTES


Upgrade existing branches to new format with commands:

  bzr infoTo see current repository format
  bzr reconcile   To correct metadata prior upgrade
  bzr upgrade To convert repository to latest format
  bzr packTo make repository faster

Following additional Cygwin modules can be also installed:

  python-paramiko - for ssh/sftp support
  python-crypto   - required by paramiko

CYGWIN INSTALLATION INFORMATION
===

To install this package, click on the "Install Cygwin now" link on the
 web page. This downloads setup.exe to your
system. Then, run setup and answer all of the questions. You'll find
the package listed in the "All" category. After installation, read the
documentation at directories:

/usr/share/doc//*
/usr/share/doc/Cygwin/.README

If you have questions or comments, please send them to the Cygwin
mailing list at .

CYGWIN-ANNOUNCE UNSUBSCRIBE INFO


This message has been sent to cygwin-announce list.

If you want to unsubscribe from the mailing list, look at the
"List-Unsubscribe: " tag in the email header of this message. Send
email to the address specified there. It will be in the format:

cygwin-announce-unsubscribe-you=yourdomain.com(at)cygwin.com

More information on unsubscribing can be found:

http://sources.redhat.com/lists.html#unsubscribe-simple

Please read *all* of the information on unsubscribing that is available
starting at the above URL.

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: Problems with terminal doesn't display visual elements properly

2011-03-20 Thread Andy Koppe
On 20 March 2011 09:18, Diego Queiroz wrote:
> On 18 March 2011 06:12, Andy Koppe wrote:
>>
>> On 17 March 2011 22:09, Diego Queiroz wrote:
>> > Hello.
>> >
>> > I need some help.
>> > My terminal started with a very strange behavior today.
>> > Many programs are not displaying correctly and I don't know why.
>> >
>> > I uploaded this picture: http://img851.imageshack.us/i/screenshotfc.png/
>> > The two windows at the top are displaying the "nano" and "top"
>> > programs using putty.
>> > The two windows at the bottom are displaying the same programs using
>> > cygwin, respectively.
>> >
>> > As you can see, the visual of the applications is different, and that's 
>> > not all.
>> > I'm really not able to work with these applications because of this
>> > problem. Actually, any visual enhancement is not working properly.
>> > Even grep with --color option isn't working correctly.
>> >
>> > In the image, both programs are connected to the same server thru ssh,
>> > so IMO the problem is not related with server configuration or any
>> > tool specific setting.
>> > The problem also occurs when using cygwin in the local machine.
>> >
>> > I'm almost sure the problem is related with the dos emulator, but I
>> > don't have an idea whats wrong.
>> > The problem started when I did the last cygwin update (but I also
>> > updated many programs in the machine together, so I don't know if
>> > cygwin caused this).
>>
>> What's the server? Are you connecting with cygwin ssh (i.e.
>> /usr/bin/ssh)? What's the TERM setting on the server? It should be
>> 'cygwin'. or, if the server doesn't know that, 'vt100' should do.
>>
>> You might also want to try mintty (where TERM should be 'xterm').
>>
>> Andy
>
> Hello Andy.
> Thanks for your reply.
>
> But it doesn't really matter.
>
> Quote:
> "IMO the problem is not related with server configuration or any tool
> specific setting. The problem also occurs when using cygwin in the
> local machine."
>
> I mean, the same problem also occurs when I am connected with no
> server at all (just the local installation of cygwin).

Right. So have you checked the TERM setting? Here's my wild guess:
you've got MS's "Subsystem for Unix Applications" (aka "Services for
Unix", aka "Interix") installed, and that's set TERM to "dumb" in the
system-wide settings.

Andy

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: IFS/read dash bug (was Re: Problems with the new base-files-4.0-5?)

2011-03-20 Thread Cyrille Lefevre


Le 19/03/2011 23:34, Cyrille Lefevre a écrit :



Le 18/03/2011 14:46, David Sastre a écrit :


[ -e "${p}" ]&& IFS=',' read -r PRINTER dummy< "${p}"


Works in bash, posh, mksh and zsh, but fails (at least for me) in
dash.


regarding SUSv3, read is not a special builtin, so, should work under
every shell, if that fails under dash, it should be fixed.


fixed in git depot as of :

2010-05-27 	Herbert Xu	[VAR] Do not poplocalvars prematurely on regular 
utilitie

http://git.kernel.org/?p=utils/dash/dash.git;a=snapshot;h=1d806ac1fbafb867f6252e184e1be05c0829ab71;sf=tgz

$ echo a b,c | ./dash -c 'IFS=, read a b; echo $a'
a b

however, there are a lot of change on 2010-05-27/28, the last one is :
http://git.kernel.org/?p=utils/dash/dash.git;a=snapshot;h=0cda2e1f8d8222fa497f808b54a2146d60e304f5;sf=tgz

how about to update dash from git since the last release is almost one 
year old ?


Regards,

Cyrille Lefevre
--
mailto:cyrille.lefevre-li...@laposte.net



--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



cygwin + GetConsoleOutputCP

2011-03-20 Thread Charles Wilson
Question about porting the upstream "dos2unix" utilities.  These
implementations provide capabilities to convert text files from a
certain limited set of INPUT encodings (most are DOS codepages):

=
CONVERSION MODES
   Conversion modes ascii, 7bit, and iso are
   similar to those of dos2unix/unix2dos under
   SunOS/Solaris.

   ascii
   In mode "ascii" only line breaks are
   converted. This is the default conversion
   mode.

   Although the name of this mode is ASCII,
   which is a 7 bit standard, the actual mode
   is 8 bit. Use always this mode when
   converting Unicode UTF-8 files.

   7bit
   In this mode all 8 bit non-ASCII characters
   (with values from 128 to 255) are converted
   to a 7 bit space.

   iso Characters are converted between a DOS
   character set (code page) and ISO character
   set ISO-8859-1 (Latin-1) on Unix. DOS
   characters without ISO-8859-1 equivalent,
   for which conversion is not possible, are
   converted to a dot. The same counts for
   ISO-8859-1 characters without DOS
   counterpart.

   When only option "-iso" is used dos2unix
   will try to determine the active code page.
   When this is not possible dos2unix will use
   default code page CP437, which is mainly
   used in the USA.  To force a specific code
   page use options "-437" (US), "-850"
   (Western European), "-860" (Portuguese),
   "-863" (French Canadian), or "-865"
   (Nordic).  Windows code page CP1252
   (Western European) is also supported with
   option "-1252". For other code pages use
   dos2unix in combination with iconv(1).
   Iconv can convert between a long list of
   character encodings.
=

So basically if you specify -iso (or --conv iso) without any of the
"input encoding specification" options like -437 etc, then dos2unix will
autodetect attempt to detect the *console* encoding.  If it succeeds,
then it will "convert" character codes from that encoding to their
equivalent in ISO-8859-1 ("Latin 1") [unconvertible codes are replaced
with an ascii dot]

Note that this autodetect, if it works, assumes that the console's CP is
the input file's CP.  Fair enough -- and it's an overridable default
anyway.  However, I wonder if, in cygwin-1.7, we actually can/should use
the "console codepage" in ANY way.  Here's the code:

querycp.c:
#elif defined (WIN32) || defined(__CYGWIN__)

/* Erwin Waterlander */

#include 
unsigned short query_con_codepage(void) {
   return((unsigned short)GetConsoleOutputCP());
}
#else

Or if instead, on cygwin, we should use some other mechanism (locale
settings?) to determine the correct default "input" codepage.

Comments?

--
Chuck




--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: ITP dos2unix 5.2.1-1

2011-03-20 Thread Charles Wilson
On 3/18/2011 2:53 AM, Charles Wilson wrote:
> On 3/17/2011 4:36 PM, Charles Wilson wrote:
>> OK, everybody, time out for a minute.  Rather than talk vapor, I'll
>> develop the patches necessary.

FYI, the first four patches

0001-cygwin-makefile-fixes.patch
0002-cygwin-defines-WIN32-but-isn-t.patch
0003-Rationalize-logic-flow.patch
0004-Add-safe-option-opposite-of-force.patch

now have patch tracker items at sourceforge.net:

0001-cygwin-makefile-fixes.patch
http://bit.ly/eJU32U

0002-cygwin-defines-WIN32-but-isn-t.patch
http://bit.ly/fczran

0003-Rationalize-logic-flow.patch
http://bit.ly/gU32y2

0004-Add-safe-option-opposite-of-force.patch
http://bit.ly/gO7n9Y

I'm going to delay the other patches until these are either accepted (in
whatever form) or rejected, because the remaining patches are have too
many overlaps with these to allow simultaneous discussion (svn is not
good at 'patch sequencing' of uncommitted patches).

--
Chuck

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



How to determine actual character set

2011-03-20 Thread Matthias Meyer
Hi,

I use cygwin 1.7.5 and run backups from Windoze to my Linux server by using 
BackupPC.
I want to set the windows character set within the backuppc configuration 
for preventing me from this filename renamings (e.g. the german "ü" will be 
replaced by "?")

But how to determine the windows character set?
chcp will only deliver the code page (850 in one of my clients).
But I need something like "cp1252"

Is there a program within cygwin which would resolve my pain ;-)

br
Matthias
-- 
Don't Panic


--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Broken autoconf mmap test

2011-03-20 Thread Ken Brown
What's the status of the broken autoconf mmap test, which always fails 
on Cygwin even though Cygwin has a working mmap?  The last message I can 
find on the cygwin list is from November 2009:


  http://cygwin.com/ml/cygwin/2009-11/msg00368.html

Was this ever resolved?  I see that cygport is still using the workaround

  export ac_cv_func_mmap_fixed_mapped=yes

in autotools.cygclass.  And I still have to do something similar when 
building texlive, even though the latter uses autoconf 2.68.


Ken

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



RE: Cygwin (1.7.8 and other versions) problems with globbing when invoked from DOS/Windows with nested quotes

2011-03-20 Thread Buchbinder, Barry (NIH/NIAID) [E]
Larry Hall (Cygwin) sent the following at Friday, March 18, 2011 6:01 PM
>On 3/18/2011 2:39 PM, Alex Khripin wrote:
>> Short summary: getting nested quotes in an argument through to a
>> Cygwin process from DOS is problematic, and there does not seem to beif you 
>> must
>> any detailed spec for how to escape quotes correctly. Backslash
>> characters seem to be spuriously generated.
>
>If you're using a native Windows 'make' with a Cygwin shell, you're
>better off making your tools consistent. Quoting mechanisms for Windows
>do not align with those used by Cygwin/Linux/Unix, so things are already
>problematic. Passing in a DOS path to a Cygwin shell and expecting the
>output to be properly quoted for a Windows version of 'make' is just
>asking for trouble. So I'd recommend staying on one side of the fence or
>the other if you want to minimize headaches.

I agree totally with Larry.  However, if you must use a mixed environment,
consider trying to get the commands into a script or batch file, convert
line endings appropriately, and then run the script with
  $ C:\cygwin\bin\bash -c script
or
  C:\> "$(cygpath -u "${COMSPEC}")" /c batch.bat

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.


Re: cygwin + GetConsoleOutputCP

2011-03-20 Thread Thomas Wolff

Am 20.03.2011 20:13, schrieb Charles Wilson:

...

Note that this autodetect, if it works, assumes that the console's CP is
the input file's CP.  Fair enough -- and it's an overridable default
anyway.  However, I wonder if, in cygwin-1.7, we actually can/should use
the "console codepage" in ANY way.  Here's the code:

querycp.c:
#elif defined (WIN32) || defined(__CYGWIN__)

/* Erwin Waterlander */

#include
unsigned short query_con_codepage(void) {
return((unsigned short)GetConsoleOutputCP());
}
#else

Or if instead, on cygwin, we should use some other mechanism (locale
settings?) to determine the correct default "input" codepage.

Comments?
On cygwin, GetConsoleOutputCP is largely irrelevant and is actually 
*not* the console's "codepage" for cygwin programs.
Therefore, defined (WIN32) and defined (__CYGWIN__) should be split and 
either setlocale or nl_langinfo should be used.


Thomas

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: How to reinvent /usr/bin/find in cygwin/gnu/gnat Ada?

2011-03-20 Thread Csaba Raduly
Hi Sigfried!

On Sat, Mar 19, 2011 at 10:09 PM,   wrote:

> I want to recursively crawl a directory tree on windows using
> cygwin/gnu/ada. I'm not sure if I should use the unix function opendir
> (and friends) or the windows functions FindFirstFile and FindNextFile.
> Maybe the opendir would be preferable since it would be portable.

It's not a question of portability. Cygwin goes to great lengths to
create a Unix/Linux compatible environment. If you want to use the
_Cygwin_ version of Ada, then you really should use opendir/readdir.

> Can someone point me to some examples of cygwin/ada programs calling a
> standard function like opendir?

This is not really a Cygwin question, but maybe this will help:
https://www2.adacore.com/gap-static/GNAT_Book/html/rts/g-dirope__adb.htm

Csaba
-- 
GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++
The Tao of math: The numbers you can count are not the real numbers.
Life is complex, with real and imaginary parts.
"Ok, it boots. Which means it must be bug-free and perfect. " -- Linus Torvalds
"People disagree with me. I just ignore them." -- Linus Torvalds

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple



Re: How to reinvent /usr/bin/find in cygwin/gnu/gnat Ada?

2011-03-20 Thread Hugh Myers
Csaba is quite correct. That said the thing to remember is the
examples of either approach are far more likely to be written in
either 'C' or 'C++' so your ability to translate from one or the other
to Ada will be the key to your success. I myself would use the
opendir/readdir combination simply because it is a 'native' approach
as it were...

--hsm

On Sun, Mar 20, 2011 at 4:31 PM, Csaba Raduly  wrote:
> Hi Sigfried!
>
> On Sat, Mar 19, 2011 at 10:09 PM,   wrote:
>
>> I want to recursively crawl a directory tree on windows using
>> cygwin/gnu/ada. I'm not sure if I should use the unix function opendir
>> (and friends) or the windows functions FindFirstFile and FindNextFile.
>> Maybe the opendir would be preferable since it would be portable.
>
> It's not a question of portability. Cygwin goes to great lengths to
> create a Unix/Linux compatible environment. If you want to use the
> _Cygwin_ version of Ada, then you really should use opendir/readdir.
>
>> Can someone point me to some examples of cygwin/ada programs calling a
>> standard function like opendir?
>
> This is not really a Cygwin question, but maybe this will help:
> https://www2.adacore.com/gap-static/GNAT_Book/html/rts/g-dirope__adb.htm
>
> Csaba
> --
> GCS a+ e++ d- C++ ULS$ L+$ !E- W++ P+++$ w++$ tv+ b++ DI D++ 5++
> The Tao of math: The numbers you can count are not the real numbers.
> Life is complex, with real and imaginary parts.
> "Ok, it boots. Which means it must be bug-free and perfect. " -- Linus 
> Torvalds
> "People disagree with me. I just ignore them." -- Linus Torvalds
>
> --
> Problem reports:       http://cygwin.com/problems.html
> FAQ:                   http://cygwin.com/faq/
> Documentation:         http://cygwin.com/docs.html
> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>
>

--
Problem reports:   http://cygwin.com/problems.html
FAQ:   http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple