Fossil

Check-in [6625739e]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:cvs2fossil: add -nocomplain flag to glob to prevent an error if no files/dirs match
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1:6625739eda3e533c36d498bbc8b86a693795e367
User & Date: mjanssen 2008-01-29 00:12:12
Context
2008-01-29
00:38
Fix a bug in the "user default" command. check-in: 0921b68f user: drh tags: trunk
00:12
cvs2fossil: add -nocomplain flag to glob to prevent an error if no files/dirs match check-in: 6625739e user: mjanssen tags: trunk
2008-01-28
23:57
Changes to cvs2fossil to import tcllib CVS into fossil on Win32

* using [::file] instead of [file] in snit methods to get the core file command * taking care of files that only differ in case in the Attic and the repo on case insensitive FS * passing platform specific check-in: 7208c7ac user: mjanssen tags: trunk

Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to tools/cvs2fossil/lib/c2f_pcollar.tcl.

112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
...
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
		if {![IsRCSArchive $path]} continue

		set usr [UserPath $rcs isattic]
		if {[IsSuperceded $base $rcs $usr $isattic]} continue

		# XXX Checkme: not sure if this will still fail in the case where a directory does conflict with a file XXX
		if {
		    [lsearch [glob -tail -types f -directory $base *] $usr] != -1 &&
		    [lsearch [glob -tail -types d -directory $base *] $usr] != -1 
		} {
		    trouble fatal "Directory name conflicts with filename."
		    trouble fatal "Please remove or rename one of the following:"
		    trouble fatal "    $base/$usr"
		    trouble fatal "    $base/$rcs"
		    continue
		}
................................................................................

    proc IsSuperceded {base rcs usr isattic} {
	::variable myignore

	if {!$isattic}                   {return 0}

	# use glob to account for case insensitive file systems 
	if {[lsearch [glob -tail -directory $base *] $usr,v] == -1} {return 0}

	# We have a regular archive and an Attic archive refering to
	# the same user visible file. Ignore the file in the Attic.
	#
	# By default this is a problem causing an abort after the pass
	# has completed. The user can however force us to ignore it.
	# In that case the warning is still printed, but will not







|
|







 







|







112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
...
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
		if {![IsRCSArchive $path]} continue

		set usr [UserPath $rcs isattic]
		if {[IsSuperceded $base $rcs $usr $isattic]} continue

		# XXX Checkme: not sure if this will still fail in the case where a directory does conflict with a file XXX
		if {
		    [lsearch [glob -nocomplain -tail -types f -directory $base *] $usr] != -1 &&
		    [lsearch [glob -nocomplain -tail -types d -directory $base *] $usr] != -1 
		} {
		    trouble fatal "Directory name conflicts with filename."
		    trouble fatal "Please remove or rename one of the following:"
		    trouble fatal "    $base/$usr"
		    trouble fatal "    $base/$rcs"
		    continue
		}
................................................................................

    proc IsSuperceded {base rcs usr isattic} {
	::variable myignore

	if {!$isattic}                   {return 0}

	# use glob to account for case insensitive file systems 
	if {[lsearch [glob -nocomplain -tail -directory $base *] $usr,v] == -1} {return 0}

	# We have a regular archive and an Attic archive refering to
	# the same user visible file. Ignore the file in the Attic.
	#
	# By default this is a problem causing an abort after the pass
	# has completed. The user can however force us to ignore it.
	# In that case the warning is still printed, but will not