public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: "Ms. Alex Hankins" <by7eth29fh@snkmail.com>
To: cygwin@cygwin.com
Subject: Re: Unison 2.43.3 fails to synchronize execute permission bit
Date: Mon, 02 Nov 2015 19:12:00 -0000	[thread overview]
Message-ID: <27710-1446491561-426587@sneakemail.com> (raw)
In-Reply-To: <CACWeX-c6RMviMhcgMjjJzQO-EVwuiQE1USgbKsTZcZep4QQeCA@mail.gmail.com>

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

There was a bug with the umask in the test script.  I have fixed it
and attached it.

On Thu, Oct 29, 2015 at 11:26 AM, L <*******************> wrote:
> On Wed, Oct 28, 2015 at 2:55 PM,  <bccme@sneakemail.com> wrote:
>> When synchronizing two directories on the same NTFS-formatted drive, unison (with -perms 0o1777) fails to set execute permissions on new files.  (It also fails to detect changes in execute permissions and to set them on existing files.)
>>...
>
> I forgot cygcheck.out.  I have attached it.
>
> Ms. Alex Hankins

[-- Attachment #2: test-whether-unison-preserves-execute-permissions.bash --]
[-- Type: application/octet-stream, Size: 1246 bytes --]

#!/usr/bin/bash

# File:  test-whether-unison-preserves-execute-permissions.bash

# Test whether unison (and the filesystem housing /tmp)
# synchronizes execute-bits on new, local files.

# Comment out to turn on script debugging:
#set -x

# We need to clean up after the test is done, so we use this flag to 
# determine the exit status later.
#
success="false"

umask 007

# Try to create a temporary directory to store all test files.
#
tmpDir="/tmp/unison.$$"
if ! mkdir "${tmpDir}"; then
  echo >&2 "${0}": cannot make temporary directory.
  exit 1
fi

export UNISON="${tmpDir}/.unison"  # Keep ~/.unison clean.
mkdir "${UNISON}"

mkdir "${tmpDir}/a" "${tmpDir}/b"
touch "${tmpDir}/a/foo"
chmod u+rwx,go= "${tmpDir}/a/foo"

echo "----- Before synchronization:"
ls -lRa "${tmpDir}"
echo

echo "----- Running unison."
unison -batch -debug all -log=false -perms 0o1777 "${tmpDir}/a" "${tmpDir}/b" 
echo

echo "----- After synchronization:"
ls -lRa "${tmpDir}"
echo

if [ -x "${tmpDir}/b/foo" ]; then
  success="true"
else
  echo >&2 "${0}: test failed (for filesystem housing /tmp): execute bit not preserved"
  success="false"
fi

# Clean up the temporary directory we made.
rm -r "${tmpDir}"

if [ "${success}" = "false" ]; then
  exit 1
fi


[-- Attachment #3: Type: text/plain, Size: 218 bytes --]

--
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

       reply	other threads:[~2015-11-02 19:12 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CACWeX-c6RMviMhcgMjjJzQO-EVwuiQE1USgbKsTZcZep4QQeCA@mail.gmail.com>
2015-11-02 19:12 ` Ms. Alex Hankins [this message]
2015-11-03 14:42   ` Andrew Schulman
2015-11-04  4:12     ` Ms. Alex Hankins
2015-11-15 19:58       ` L
2015-11-15 20:00       ` Ms. Alex Hankins
2015-10-29 16:14 Ms. Alex Hankins
  -- strict thread matches above, loose matches on Subject: below --
2015-10-29  3:09 Alex

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=27710-1446491561-426587@sneakemail.com \
    --to=by7eth29fh@snkmail.com \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).