Thanks for your effort. I remember too that inodes simply does not exists on win. Can that number be something derived from Master File Table? i'm guessing only.
Anyway the number are consistent, more: they are consistent even for hard links, and using stat (maybe next hour inspecting stat.c ;=)..):
>touch test02.txt
>C:\SCRIPTS\GnuWin32-bis\bin\ls.exe -il test02.txt
12666373953464529 -rw-rw-rw- 1 lt 0 0 2014-11-13 11:26 test02.txt
>C:\SCRIPTS\GnuWin32-bis\bin\ln test02.txt link-to-test02.txt
>C:\SCRIPTS\GnuWin32-bis\bin\ls.exe -il test02.txt link-to-test02.txt
12666373953464529 -rw-rw-rw- 2 lt 0 0 2014-11-13 11:26 link-to-test02
+.txt
12666373953464529 -rw-rw-rw- 2 lt 0 0 2014-11-13 11:26 test02.txt
>echo Perl > test02.txt
>cat test02.txt
Perl
>cat link-to-test02.txt
Perl
>C:\SCRIPTS\GnuWin32-bis\bin\ls.exe -il test02.txt link-to-test02.txt
12666373953464529 -rw-rw-rw- 2 lt 0 7 2014-11-13 11:28 link-to-test02
+.txt
12666373953464529 -rw-rw-rw- 2 lt 0 7 2014-11-13 11:28 test02.txt
>C:\SCRIPTS\GnuWin32-bis\bin\stat -c "%i %N" test02.txt
12666373953464529 `test02.txt'
>C:\SCRIPTS\GnuWin32-bis\bin\stat -c "%i %N\n" link-to-test02.txt
12666373953464529 `link-to-test02.txt'
L*
UPDATE:
they state explicitely
here:
st_ino
Number of the information node (the inode) for the file (UNIX-specific). On UNIX file systems, the inode describes the file date and time stamps, permissions, and content. When files are hard-linked to one another, they share the same inode. The inode, and therefore st_ino, has no meaning in the FAT, HPFS, or NTFS file systems.L*
UPDATE BIS:
C:\Windows\system32>fsutil file queryfileid c:\SCRIPTS\test02.txt
ID del file: 0x002d00000016a8d1
C:\Windows\system32>fsutil file queryfilenamebyid c:\ 0x002d00000016a
+8d1
Nome collegamento causale al file: \\?\C:\SCRIPTS\test02.txt
#0x002d00000016a8d1 hex is equal to 12666373953464529 dec (the same nu
+mber as above!!!)
L*
There are no rules, there are no thumbs..
Reinvent the wheel, then learn The Wheel; may be one day you reinvent one of THE WHEELS.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.