<meta http-equiv="Content-Type" content="text/html; charset=GB18030"><blockquote formatblock="1" style="margin: 0.8em 0px 0.8em 2em; padding: 0px 0px 0px 0.7em; border-left: 2px solid rgb(221, 221, 221);"><span style="font-family: sans-serif;">Most likely though electron-vue would use kqueue() or FSEvents to just detect that “something changed” in the directory and not actually look at file modification dates to verify that file data has actually changed.</span></blockquote><div><div><br></div><div>Thank you! I found that electron-vue dependencies include fsevent.</div><div><br></div><div style="font-size: 12px;font-family: Arial Narrow;padding:2px 0 2px 0;">------------------ 原始邮件 ------------------</div><div style="font-size: 12px;background:#efefef;padding:8px;"><div><b>发件人:</b> "Allan Odgaard"<mailinglist@textmate.org>;</div><div><b>发送时间:</b> 2020年3月30日(星期一) 凌晨0:04</div><div><b>收件人:</b> "TextMate users"<textmate@lists.macromates.com>;<wbr></div><div></div><div><b>主题:</b> [TxMt] Re: Why does textmate modify the file mtime after closing the tab?</div></div><div><br></div>





<div style="font-family:sans-serif"><div style="white-space:normal">
<p dir="auto">On 29 Mar 2020, at 22:22, Marc Wilson wrote:</p>

</div>
<div style="white-space:normal"><blockquote style="border-left:2px solid #777; color:#777; margin:0 0 5px; padding-left:5px"><p dir="auto">I'm not saying you're wrong (I have no idea), but Howard says:<br>
<br>
"Changing a file’s xattrs doesn’t alter the data in the file itself. Xattrs aren’t even stored in the main data area of a volume, but apart, in the file system metadata. So adding or changing a xattr won’t change the date of modification, nor the date that the file was last opened.</p>
</blockquote></div>
<div style="white-space:normal">

<p dir="auto">This is true, however, there is also a “time of last file status change” which <em>does</em> change when extended attributes are updated.</p>

<p dir="auto">Most likely though electron-vue would use kqueue() or FSEvents to just detect that “something changed” in the directory and not actually look at file modification dates to verify that file data has actually changed.</p>

</div>
<div style="white-space:normal"><blockquote style="border-left:2px solid #777; color:#777; margin:0 0 5px; padding-left:5px"><p dir="auto">I'm wondering how to test something like that. :)</p>
</blockquote></div>
<div style="white-space:normal">

<p dir="auto">Here’s a test:</p>

<pre style="background-color:#F7F7F7; border-radius:5px 5px 5px 5px; margin-left:15px; margin-right:15px; max-width:90vw; overflow-x:auto; padding:5px" bgcolor="#F7F7F7"><code style="background-color:#F7F7F7; border-radius:3px; margin:0; padding:0" bgcolor="#F7F7F7">% stat test.txt|grep Change
Change: 2020-03-29 22:55:57.799348845 +0700
% xattr -w foo bar test.txt
% stat test.txt|grep Change
Change: 2020-03-29 23:02:02.450048038 +0700
</code></pre>
</div>
</div></div>