Revision: arch--lord--1.0--patch-13
Archive: lord@regexps.com--2002
Creator: Tom Lord <lord@regexps.com>
Date: Tue Jan  8 15:53:11 PST 2002
Standard-date: 2002-01-08
Summary: Use --dir consistently.
Keywords: 
New-files: {arch}/arch/arch--lord/arch--lord--1.0/lord@regexps.com--2002/patch-log/patch-13
Removed-files: local-cache/wd-new-patches.sh inventory/inventory-pkgtest.sh
Modified-files: =TODO ChangeLog
  ChangeLog.d/lord@regexps.com--2002/ChangeLog.lord--1.0
  archive-transactions/commit.sh
  archive-transactions/import.sh
  branching-and-merging/finish-branch.sh
  inventory/check-manifest.sh inventory/manifest.sh
  inventory/set-manifest.sh inventory/tagging-method.sh
  inventory/tree-lint.sh local-cache/add-pristine.sh
  local-cache/delete-pristine.sh local-cache/lock-pristine.sh
  patch-logs/add-log.sh patch-logs/cat-log.sh
  patch-logs/make-log.sh project-tree/init-tree.sh
  project-tree/set-tree-version.sh
New-patches: lord@regexps.com--2002/arch--lord--1.0--patch-13


In these commands:

	commit
	import
	add-log
	cat-log
	make-log
	init-tree
	set-tree-version
	tagging-method
	add-pristine
	delete-pristine

use a `--dir' option argument, not an optional `dir' argument.

The syntax of commands with an optional directory parameter is
confusing if there are other optional arguments -- those commands
*must* use --dir.  Other commands with an optional dir parameter
should therefore use --dir for consistency.

There are some excpetions.  If a command follows the pattern:

	COPY FROM [TO]

(where TO has a reasonable default), an optional TO argument is fine,
even if that argument is a directory: this emulates `cp' and `mv'.
(`get' and `get-patch' are examples).

If a command follows the pattern:

	LIST-SOME-FILES-OR-FILE-LIKE-OBJECTS [IN]

where IN has a reasonable default, then an optional IN argument is
fine, even if that argument is a directory: this emulates `ls'.
(`inventory' and `manifest' are examples).

If a command takes an optional dir parameter, but does not now nor is
every likely to have any other position parameters, and the optional
dir parameter is pretty central to the command, the dir parameter
should be an optional argument.  (`tree-repair' is an example.)

Some commands take a variable number of dir arguments (e.g. `replay')
but none of them are optional.  Then number required is determined by
earlier options.  It isn't sensible to make some of dir arguments
arguments to those options, because positional ordering of arguments
is significant (e.g. `star-merge').


Other random clean-ups that came up:

`wd-new-patches': removed.  Dead code.
`inventory-pkgtest': removed. Dead Code.

`tree-lint': usage message fix.
`lock-pristine': usage message fix.

