The mkmed-version program

mkmed-version {-n|-o} /path/to/foo-1.0 /path/to/foo-2.0 [program arg ...]

mkmed-version creates a new package version (foo-2.0) as a copy of an existing version (foo-1.0). One of -n or -o must be given. -n creates a "new" version: the src/as-is/package/versions file of the created version will include the number of the existing version. -o creates an "old" version: the number of the created version is added to the existing version's src/as-is/package/versions. Finally, if any arguments are given after the new package version path, mkmed-version runs the given command.