Artifact c1f7d034eab99b083547f6059cdd93c9ef6da6e3:
Wiki page
[fossil ls]
by
kejoki on
2008-11-09 20:52:27.
0000: 44 20 32 30 30 38 2d 31 31 2d 30 39 54 32 30 3a D 2008-11-09T20:
0010: 35 32 3a 32 37 0a 4c 20 66 6f 73 73 69 6c 5c 73 52:27.L fossil\s
0020: 6c 73 0a 50 20 39 34 61 62 33 64 38 61 61 33 64 ls.P 94ab3d8aa3d
0030: 63 35 39 31 64 61 32 33 66 30 39 33 35 35 32 39 c591da23f0935529
0040: 37 30 38 63 30 39 30 61 32 65 65 62 32 0a 55 20 708c090a2eeb2.U
0050: 6b 65 6a 6f 6b 69 0a 57 20 32 31 34 33 0a 3c 68 kejoki.W 2143.<h
0060: 32 3e 6c 73 3c 2f 68 32 3e 0d 0a 0d 0a 54 68 65 2>ls</h2>....The
0070: 20 3c 63 6f 64 65 3e 6c 73 3c 2f 63 6f 64 65 3e <code>ls</code>
0080: 20 63 6f 6d 6d 61 6e 64 20 69 73 20 69 6e 66 6f command is info
0090: 72 6d 61 74 69 6f 6e 61 6c 2c 20 69 74 20 64 6f rmational, it do
00a0: 65 73 6e 27 74 20 64 6f 20 61 6e 79 74 68 69 6e esn't do anythin
00b0: 67 20 74 6f 0d 0a 61 20 63 68 65 63 6b 65 64 2d g to..a checked-
00c0: 6f 75 74 20 70 72 6f 6a 65 63 74 2c 20 62 75 74 out project, but
00d0: 20 69 74 20 74 65 6c 6c 73 20 79 6f 75 20 73 6f it tells you so
00e0: 6d 65 74 68 69 6e 67 20 61 62 6f 75 74 20 69 74 mething about it
00f0: 2e 0d 0a 0d 0a 41 20 70 72 6f 6a 65 63 74 20 63 .....A project c
0100: 6f 6e 73 69 73 74 73 20 6f 66 20 61 20 22 73 6f onsists of a "so
0110: 75 72 63 65 20 74 72 65 65 22 20 6f 66 20 22 61 urce tree" of "a
0120: 72 74 69 66 61 63 74 73 22 20 28 73 65 65 20 3c rtifacts" (see <
0130: 61 20 68 72 65 66 3d 22 64 6f 63 2f 74 69 70 2f a href="doc/tip/
0140: 77 77 77 2f 63 6f 6e 63 65 70 74 73 2e 77 69 6b www/concepts.wik
0150: 69 22 3e 46 6f 73 73 69 6c 20 63 6f 6e 63 65 70 i">Fossil concep
0160: 74 73 3c 2f 61 3e 2e 29 0d 0a 46 72 6f 6d 20 61 ts</a>.)..From a
0170: 20 70 72 61 63 74 69 63 61 6c 20 73 74 61 6e 64 practical stand
0180: 70 6f 69 6e 74 20 74 68 69 73 20 69 73 20 61 20 point this is a
0190: 73 65 74 20 6f 66 20 66 69 6c 65 73 20 61 6e 64 set of files and
01a0: 20 64 69 72 65 63 74 6f 72 69 65 73 20 72 6f 6f directories roo
01b0: 74 65 64 0d 0a 61 74 20 61 20 6d 61 69 6e 20 70 ted..at a main p
01c0: 72 6f 6a 65 63 74 20 64 69 72 65 63 74 6f 72 79 roject directory
01d0: 2e 20 20 54 68 65 20 66 69 6c 65 73 20 74 68 61 . The files tha
01e0: 74 20 61 72 65 20 75 6e 64 65 72 20 73 6f 75 72 t are under sour
01f0: 63 65 20 63 6f 6e 74 72 6f 6c 20 61 72 65 6e 27 ce control aren'
0200: 74 0d 0a 70 61 72 74 69 63 75 6c 61 72 6c 79 20 t..particularly
0210: 64 69 73 74 69 6e 67 75 69 73 68 61 62 6c 65 20 distinguishable
0220: 66 72 6f 6d 20 74 68 6f 73 65 20 74 68 61 74 20 from those that
0230: 61 72 65 6e 27 74 2e 20 20 54 68 65 20 3c 63 6f aren't. The <co
0240: 64 65 3e 6c 73 3c 2f 63 6f 64 65 3e 20 61 6e 64 de>ls</code> and
0250: 0d 0a 3c 63 6f 64 65 3e 65 78 74 72 61 3c 2f 63 ..<code>extra</c
0260: 6f 64 65 3e 20 63 6f 6d 6d 61 6e 64 73 20 70 72 ode> commands pr
0270: 6f 76 69 64 65 20 74 68 69 73 20 69 6e 66 6f 72 ovide this infor
0280: 6d 61 74 69 6f 6e 2e 0d 0a 0d 0a 3c 63 6f 64 65 mation.....<code
0290: 3e 66 6f 73 73 69 6c 20 6c 73 3c 2f 63 6f 64 65 >fossil ls</code
02a0: 3e 20 70 72 6f 64 75 63 65 73 20 61 20 6c 69 73 > produces a lis
02b0: 74 69 6e 67 20 6f 66 20 74 68 65 20 66 69 6c 65 ting of the file
02c0: 73 20 77 68 69 63 68 20 61 72 65 20 75 6e 64 65 s which are unde
02d0: 72 20 73 6f 75 72 63 65 0d 0a 63 6f 6e 74 72 6f r source..contro
02e0: 6c 20 3c 69 3e 61 6e 64 3c 2f 69 3e 20 74 68 65 l <i>and</i> the
02f0: 69 72 20 73 74 61 74 75 73 20 77 69 74 68 69 6e ir status within
0300: 20 74 68 65 20 72 65 70 6f 73 69 74 6f 72 79 2e the repository.
0310: 20 20 54 68 65 20 6f 75 74 70 75 74 20 69 73 20 The output is
0320: 61 20 73 69 6d 70 6c 65 0d 0a 6c 69 73 74 20 6f a simple..list o
0330: 66 20 53 54 41 54 55 53 2f 66 69 6c 65 70 61 74 f STATUS/filepat
0340: 68 20 70 61 69 72 73 20 6f 6e 20 73 65 70 61 72 h pairs on separ
0350: 61 74 65 20 6c 69 6e 65 73 2e 20 20 54 68 65 20 ate lines. The
0360: 73 74 61 74 75 73 20 6f 66 20 61 20 66 69 6c 65 status of a file
0370: 20 77 69 6c 6c 0d 0a 6c 69 6b 65 6c 79 20 62 65 will..likely be
0380: 20 6f 6e 65 20 6f 66 20 41 44 44 45 44 2c 20 55 one of ADDED, U
0390: 4e 43 48 41 4e 47 45 44 2c 20 55 50 44 41 54 45 NCHANGED, UPDATE
03a0: 44 2c 20 6f 72 20 44 45 4c 45 54 45 44 2e 0d 0a D, or DELETED...
03b0: 0d 0a 49 74 27 73 20 69 6d 70 6f 72 74 61 6e 74 ..It's important
03c0: 20 74 6f 20 72 65 61 6c 69 7a 65 20 74 68 61 74 to realize that
03d0: 20 74 68 69 73 20 69 73 20 74 68 65 20 73 74 61 this is the sta
03e0: 74 75 73 20 3c 69 3e 72 65 6c 61 74 69 76 65 20 tus <i>relative
03f0: 74 6f 20 74 68 65 20 72 65 70 6f 73 69 74 6f 72 to the repositor
0400: 79 3c 2f 69 3e 2c 0d 0a 69 74 27 73 20 74 68 65 y</i>,..it's the
0410: 20 73 74 61 74 75 73 20 61 73 20 3c 62 3e 66 6f status as <b>fo
0420: 73 73 69 6c 3c 2f 62 3e 20 73 65 65 73 20 69 74 ssil</b> sees it
0430: 20 61 6e 64 20 68 61 73 20 6e 6f 74 68 69 6e 67 and has nothing
0440: 20 74 6f 20 64 6f 20 77 69 74 68 0d 0a 66 69 6c to do with..fil
0450: 65 73 79 73 74 65 6d 20 73 74 61 74 75 73 2e 20 esystem status.
0460: 20 49 66 20 79 6f 75 27 72 65 20 6e 65 77 20 74 If you're new t
0470: 6f 20 73 6f 75 72 63 65 2d 6d 61 6e 61 67 65 6d o source-managem
0480: 65 6e 74 2f 76 65 72 73 69 6f 6e 2d 63 6f 6e 74 ent/version-cont
0490: 72 6f 6c 0d 0a 73 79 73 74 65 6d 73 2c 20 79 6f rol..systems, yo
04a0: 75 27 6c 6c 20 70 72 6f 62 61 62 6c 79 20 67 65 u'll probably ge
04b0: 74 20 62 69 74 20 62 79 20 74 68 69 73 20 63 6f t bit by this co
04c0: 6e 63 65 70 74 2d 62 75 67 20 61 74 20 6c 65 61 ncept-bug at lea
04d0: 73 74 20 6f 6e 63 65 2e 0d 0a 0d 0a 54 6f 20 72 st once.....To r
04e0: 65 61 6c 6c 79 20 73 65 65 20 74 68 65 20 64 69 eally see the di
04f0: 66 66 65 72 65 6e 63 65 2c 20 69 73 73 75 65 20 fference, issue
0500: 61 6e 20 3c 63 6f 64 65 3e 6c 73 3c 2f 63 6f 64 an <code>ls</cod
0510: 65 3e 20 62 65 66 6f 72 65 20 61 6e 64 20 61 66 e> before and af
0520: 74 65 72 20 64 6f 69 6e 67 0d 0a 61 20 3c 63 6f ter doing..a <co
0530: 64 65 3e 63 6f 6d 6d 69 74 3c 2f 63 6f 64 65 3e de>commit</code>
0540: 2e 20 20 42 65 66 6f 72 65 2c 20 74 68 65 20 73 . Before, the s
0550: 74 61 74 75 73 20 6f 66 20 66 69 6c 65 73 20 6d tatus of files m
0560: 61 79 20 62 65 20 61 6e 79 20 6f 66 20 74 68 65 ay be any of the
0570: 20 74 68 72 65 65 2c 0d 0a 62 75 74 20 61 66 74 three,..but aft
0580: 65 72 20 3c 63 6f 64 65 3e 63 6f 6d 6d 69 74 3c er <code>commit<
0590: 2f 63 6f 64 65 3e 74 69 6e 67 20 63 68 61 6e 67 /code>ting chang
05a0: 65 73 20 74 68 65 20 73 74 61 74 75 73 20 77 69 es the status wi
05b0: 6c 6c 20 62 65 20 55 4e 43 48 41 4e 47 45 44 20 ll be UNCHANGED
05c0: 22 61 63 72 6f 73 73 0d 0a 74 68 65 20 62 6f 61 "across..the boa
05d0: 72 64 2e 22 0d 0a 0d 0a 42 79 20 77 61 79 20 6f rd."....By way o
05e0: 66 20 65 78 61 6d 70 6c 65 2c 20 68 65 72 65 27 f example, here'
05f0: 73 20 77 68 61 74 20 49 20 73 65 65 20 69 66 20 s what I see if
0600: 49 20 3c 63 6f 64 65 3e 66 6f 73 73 69 6c 20 6c I <code>fossil l
0610: 73 3c 2f 63 6f 64 65 3e 20 69 6e 20 74 68 65 0d s</code> in the.
0620: 0a 64 69 72 65 63 74 6f 72 79 20 77 68 65 72 65 .directory where
0630: 20 49 20 68 61 76 65 20 63 68 65 63 6b 65 64 20 I have checked
0640: 6f 75 74 20 6d 79 20 74 65 73 74 69 6e 67 20 72 out my testing r
0650: 65 70 6f 73 69 74 6f 72 79 3a 0d 0a 3c 6e 6f 77 epository:..<now
0660: 69 6b 69 3e 3c 70 72 65 3e 0d 0a 20 20 20 20 24 iki><pre>.. $
0670: 20 66 6f 73 73 69 6c 20 6c 73 0d 0a 20 20 20 20 fossil ls..
0680: 41 44 44 45 44 20 20 20 20 20 66 65 65 67 62 6f ADDED feegbo
0690: 69 6e 67 0d 0a 20 20 20 20 55 4e 43 48 41 4e 47 ing.. UNCHANG
06a0: 45 44 20 66 6f 73 73 69 6c 5f 64 6f 63 73 2e 74 ED fossil_docs.t
06b0: 78 74 0d 0a 20 20 20 20 44 45 4c 45 54 45 44 20 xt.. DELETED
06c0: 20 20 6e 69 62 63 72 6f 64 0d 0a 3c 2f 70 72 65 nibcrod..</pre
06d0: 3e 3c 2f 6e 6f 77 69 6b 69 3e 0d 0a 42 75 74 20 ></nowiki>..But
06e0: 69 66 20 49 20 64 6f 20 61 20 73 69 6d 70 6c 65 if I do a simple
06f0: 20 6c 73 2c 20 77 68 61 74 20 49 20 67 65 74 20 ls, what I get
0700: 69 73 0d 0a 3c 6e 6f 77 69 6b 69 3e 3c 70 72 65 is..<nowiki><pre
0710: 3e 0d 0a 20 20 20 20 24 20 6c 73 0d 0a 20 20 20 >.. $ ls..
0720: 20 66 65 65 67 62 6f 69 6e 67 20 20 66 6f 73 73 feegboing foss
0730: 69 6c 5f 64 6f 63 73 2e 74 78 74 20 20 6d 61 6e il_docs.txt man
0740: 69 66 65 73 74 2e 75 75 69 64 20 20 6e 6f 6f 64 ifest.uuid nood
0750: 6c 65 2e 74 78 74 0d 0a 20 20 20 20 5f 46 4f 53 le.txt.. _FOS
0760: 53 49 4c 5f 20 20 20 6d 61 6e 69 66 65 73 74 20 SIL_ manifest
0770: 20 20 20 20 20 20 20 20 6e 69 62 63 72 6f 64 0d nibcrod.
0780: 0a 3c 2f 70 72 65 3e 3c 2f 6e 6f 77 69 6b 69 3e .</pre></nowiki>
0790: 0d 0a 0d 0a 54 68 65 20 3c 63 6f 64 65 3e 6c 73 ....The <code>ls
07a0: 3c 2f 63 6f 64 65 3e 20 63 6f 6d 6d 61 6e 64 20 </code> command
07b0: 69 73 20 61 6c 6d 6f 73 74 2c 20 62 75 74 20 6e is almost, but n
07c0: 6f 74 20 71 75 69 74 65 20 65 6e 74 69 72 65 6c ot quite entirel
07d0: 79 2c 20 74 68 65 20 65 78 61 63 74 0d 0a 6f 70 y, the exact..op
07e0: 70 6f 73 69 74 65 20 6f 66 20 74 68 65 0d 0a 3c posite of the..<
07f0: 61 20 68 72 65 66 3d 22 77 69 6b 69 3f 6e 61 6d a href="wiki?nam
0800: 65 3d 66 6f 73 73 69 6c 2b 65 78 74 72 61 22 3e e=fossil+extra">
0810: 3c 63 6f 64 65 3e 65 78 74 72 61 3c 2f 63 6f 64 <code>extra</cod
0820: 65 3e 20 63 6f 6d 6d 61 6e 64 3c 2f 61 3e 2e 0d e> command</a>..
0830: 0a 0d 0a 53 65 65 20 61 6c 73 6f 3a 20 5b 66 6f ...See also: [fo
0840: 73 73 69 6c 20 61 64 64 5d 2c 20 5b 66 6f 73 73 ssil add], [foss
0850: 69 6c 20 72 6d 5d 2c 20 5b 66 6f 73 73 69 6c 20 il rm], [fossil
0860: 65 78 74 72 61 5d 2c 20 5b 66 6f 73 73 69 6c 20 extra], [fossil
0870: 63 6f 6d 6d 69 74 5d 2c 20 3c 61 20 68 72 65 66 commit], <a href
0880: 3d 22 64 6f 63 2f 74 69 70 2f 77 77 77 2f 63 6f ="doc/tip/www/co
0890: 6e 63 65 70 74 73 2e 77 69 6b 69 22 3e 46 6f 73 ncepts.wiki">Fos
08a0: 73 69 6c 20 63 6f 6e 63 65 70 74 73 3c 2f 61 3e sil concepts</a>
08b0: 2c 20 5b 52 65 66 65 72 65 6e 63 65 5d 0a 5a 20 , [Reference].Z
08c0: 31 64 66 66 65 63 30 34 39 62 31 38 61 65 65 31 1dffec049b18aee1
08d0: 35 62 33 35 66 62 30 64 34 35 39 61 38 32 31 33 5b35fb0d459a8213
08e0: 0a .