public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Steve Ward <steveward50@hotmail.com>
To: "cygwin@cygwin.com" <cygwin@cygwin.com>
Subject: Editing with vim clears Windows 10 file system archive bit.
Date: Sun, 14 Nov 2021 18:56:29 +0000	[thread overview]
Message-ID: <SN6PR04MB4799AEB60421601D02E22680BB979@SN6PR04MB4799.namprd04.prod.outlook.com> (raw)

Description of problem:
While using vim 8.2 on cygwin 3.3 (x86_64) on Windows 10,
when editing an existing file with vim and saving it, the Window’s
file system archive bit is always left cleared (not modified state).
This happens, whether the archive bit was set (is modified) or
clear (not modified) initially.  Window’s backup tools rely on this
archive bit for making incremental backups.

The following scenarios DO work:
1. Using vim to create a new file,
   leaves the new file’s archive bit set (is modified).
2. “cp” and redirect with append (“>>”),
   leave the target file’s archive bit set (is modified).
3. “emacs” (emacs-w32) (ver. 27.2) worked for both editing and creating!
4. Editing with vim sets the “last modified date” correctly
   for Linux and Windows.

Tools used to confirm the problem:
The cygwin tool, “cygcheck –c” listed “OK” as the status of every package.
The archive bit settings were confirmed with Window’s “File Explorer” and
cygwin’s “attrib”.
The cygwin tool, “chattr,” could be used as a crude workaround,
but I rather have vim do it.

My search for solutions:
I have perused 8 years of “The Cygwin Archives” for this issue,
but could find nothing relevant.
Google Web searches, and stackoverflow.com, vim.org and
vi.stackexchange.com searches turned up nothing relevant.
On my local machine, a search of /usr/share/vim/vim82/doc/*.txt
turned up nothing relevant.

My update history:
10/2013 Cygwin-1.7.25 Windows  8 vim-7.3.1314 No problem with archive bit.
09/2021 Cygwin-3.2.0  Windows 10 vim-8.2.0486 Problem with archive bit.
11/2021 Cygwin-3.3.2  Windows 10 vim-8.2.0486 Problem with archive bit.

Can anyone shed some light on this issue?

Thanks,
Steve

Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows


             reply	other threads:[~2021-11-14 18:56 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-11-14 18:56 Steve Ward [this message]
2021-11-15 18:54 ` Christian Franke
2021-11-15 20:05   ` Corinna Vinschen
2021-11-15 22:18     ` Gary Johnson
2021-11-16 14:06       ` Corinna Vinschen

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=SN6PR04MB4799AEB60421601D02E22680BB979@SN6PR04MB4799.namprd04.prod.outlook.com \
    --to=steveward50@hotmail.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).