delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2004/09/28/13:10:08

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
To: Cygwin List <cygwin AT cygwin DOT com>
Subject: Re: unison doesn't honor HOME when USERPROFILE is set, also permission/uid/gid problems when synchronizing
References: <87oejqvmsl DOT fsf AT vzell-de DOT de DOT oracle DOT com> <MPG DOT 1bc3442639d8f8549896a6 AT localhost>
From: "Dr. Volker Zell" <Dr DOT Volker DOT Zell AT oracle DOT com>
Date: Tue, 28 Sep 2004 19:09:57 +0200
In-Reply-To: <MPG.1bc3442639d8f8549896a6@localhost> (Andrew Schulman's message of "Tue, 28 Sep 2004 11:03:15 -0400")
Message-ID: <87hdpiqpzu.fsf@vzell-de.de.oracle.com>
User-Agent: Gnus/5.1006 (Gnus v5.10.6) XEmacs/21.4 (Security Through Obscurity, cygwin32)
MIME-Version: 1.0
X-IsSubscribed: yes

>>>>> Andrew Schulman writes:

    > (1) Unison is looking in $UNISON last.  This is clearly wrong, and if 
    > fixed would allow you to solve your problem by setting 
    > UNISON=/home/volker/.unison.  But here's something I don't understand:  
    > on my Cygwin host both UNISON and USERPROFILE are set, but UNISON takes 
    > precedence. ?? Are you sure this section of code is the operative one 
    > here?  What happens if you export UNISON=/home/vzell/.unison?

In that case it will use $UNISON.
According to the file strings.ml:

      \032  Unison stores a variety of information in a private directory on each\n\
      \032  host. If the environment variable UNISON is defined, then its value\n\
      \032  will be used as the name of this directory. If UNISON is not defined,\n\
      \032  then the name of the directory depends on which operating system you\n\
      \032  are using. In Unix, the default is to use $HOME/.unison. In Windows,\n\
      \032  if the environment variable USERPROFILE is defined, then the directory\n\
      \032  will be $USERPROFILE\\.unison; otherwise if HOME is defined, it will be\n\
      \032  $HOME\\.unison; otherwise, it will be c:\\.unison.\n\
      \032  \n\

    > (2) It seems that Unison treats Cygwin as a Windows OS for this purpose, 
    > so that it looks in $USERPROFILE/.unison before $HOME/.unison.  This is 
    > arguably wrong, but I think I'll have to pose the question on unison-
    > hackers.

    >> --- uicommon.ml.orig    2004-09-28 09:43:28.010992000 +0200
    >> +++ uicommon.ml 2004-09-28 08:41:27.090571200 +0200
    >> @@ -346,7 +346,7 @@
    >> let someHostIsCaseInsensitive =
    >> someHostIsRunningWindows || someHostRunningOsX in
    >> Case.init someHostIsCaseInsensitive;
    >> -  Props.init someHostIsRunningWindows;
    >> +(*  Props.init someHostIsRunningWindows; *)
    >> Osx.init someHostRunningOsX;
    >> return ())

    > And this patch solves the owner and group sync problem?  Sorry but it's 
    > not obvious to me.

I can't remember where it comes from, it's to long ago. I can only say
it does.

    > You say Unison "didn't honor" the owner and group preferences.  What 
    > exactly happened?  Did it just not sync the owners and groups, or did it 
    > give you error messages?

It did not sync the owners and groups, no errors. And for example if you
have two dirs in sync and now create a new file (umask 0022) in one of
them, then chmod 755 it, your version in my case creates the file in the
other dir with 644 permissions. With my patch it works the sync-ed file
also has 755.

    > Thanks for your report.  As soon as I'm sure that I have the right 
    > corrections, I'll release a new version that includes the fixes.

    > Andrew.

Ciao
  Volker


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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019