pvc

pvc [command] [files]
http://news.nopcode.org/pvc/pvc.pdf
or
http://news.nopcode.org/pvc/pvc.txt
http://news.nopcode.org/pvcroot/pvc-0.7.tar.gz
http://news.nopcode.org/miau/pvc.cgi?prj=pvc
pvc is the plastic version control system.
It is filesystem-based version control system targeting vnix systems aiming simplicity and flexibility.
Their repositories are named worlds, they are composed by lands (branches), trees and leafs (files).
A special tree called 'current' contains references to the leafs in use to be commited to the next tree.
A commit just plants a new tree into the current land with the contents of the current tree.
Each land contains a reference to the last planted tree. So you can switch between lands, chopping trees and diffing leafs between them.
pvc comes with some extra programs like 'pvc.mail' to send mails of commits, 'pvc.cgi' to serve a repository via web and 'pvc2gml' to generate a gml file containing a graph of the selected pvc land.
initialize the repository
show information of the current repository
shows a timeline report of the current land
shows a report of the specified tree level. Will notify (N)ew files, (U)pdated files and (C)hanged files.
Without arguments, the resulting report will be diffing the current tree against the head one. (pre-commit)
shows the version of pvc
shows the project name
resolves a hash from/to file name.
adds new files to the current tree of the repository
removes a file from the current tree. Use hooks to remove the local copy:
$ echo 'for my $file (@arg) { unlink $file; }' > .pvc/hook/rm
show the contents of the target file. File can be a tree or a land too
moves or renames a file
list all files of the current tree in the current directory. Use -r to recursive mode. You can specify the tree hash or land name.
List all revisions of the target leaf. Command 'levels' is an alias for revs. This command is an alias for revs.
list all files of the current tree without noisy data. Use '-r' to recusively walk directories.
Only lists filenames.
list all directories of the current tree without noisy data.
changes or creates a new land or list all the owned lands if no argument given. If you specify the second argument the tree hash will be used for the head tree of the land.
sets the contents of the local file to the leaf of the current tree
sets the contents of the local file to the leaf of the head's tree
Resets the contents of .pvc/tree/current/* with the ones in .pvc/tree/[tree]/. This will remove all your local changes done in the current tree.
prints the hash of the tree at a certain level (starting from 0 (the latest)).
negative values are handled as absolute and can be used to get from the older tree.
resets the contents of the local copy file with the leaf of the current tree
downgrades the file revision to the previous one if available
upgrades the file revision to the next one if available
list all the files from the current directory that are missing in your current tree
plants a new tree in the current land with the contents of the current tree
Optionally you can directly provide the commit message to the tree's log else it will use $EDITOR environment variable or 'vi' to interactively edit the commit log message.
If you set 'vim' for $EDITOR it will split the log view with the commit diff. Note that new files will not be listed there.
The commit message can be modified in the future with 'pvc edit'
uploads a distribution tarball to the remote pvcroot. This is:
$ scp `pvc dist` `cat .pvc/remote`/..
show the differences of the current land against the local copy if no arguments given.
If you only specify the source file it will show the differences of the target file of the local copy against the copy in the current tree.
Specifying both source and destination shows the difference between the targets lands, trees or leafs.
To see the changes to be commited type: 'pvc diff . current'. This command shows the differences between the last commited tree of the current land and the current tree.
show the 'pvc diff' of the tree found at depth level compared to the parent one (level+1).
updates the revision of the target files. If you specify no files it will show a list of all the files that need to be updated
This is the interactive version of 'up'. To prepare the commit you can use this command in this way: $ pvc wz $ pvc diff . current > /tmp/diff $ pvc ci :sp /tmp/diff
removes the pointer to the parent tree.
removes the target tree chaining parent and son ones
pushes the current repository to the remote one. This command uses rsync.
You can force the operation to be non-interactive with the '-f' flag. We can also define an alternative remote instead of the .pvc/remote one.
pulls the remote repository to the current one. This command uses rsync
cleans the repository purging the unreferenced leafs and trees
recursively walks and prints the history of the current land, tree or leaf
recursively prints the parent hashes of a tree
prints the hash value of the head's tree of the current selected land.
prints the hash value of the parent tree of the head one
traces the history of a file across the tree's hirearchy
creates a tarball named pvc.tar.gz with the contents of .pvc/
merges a tree into the current tree and prompts you for the manual merge wizard.
creates a distribution tarball in the parent directory using the name of the directory as a project name and .pvc/version as the version number ( pkgname-version.tar.gz )
pvc stores all the versioning information into a filesystem tree.
contains the user@host identifier. Used by 'pvc commit'
contains the version of the current local copy. Used by 'pvc dist'
contains the path to the remote ssh or local path repository. Used by 'pvc push' and 'pvc pull'
contains one regular expression per line. Matching filenames will be ignored. Default one is: ^\. \/\. .*\.o$ .*\.so$ Makefile$
contains the name of the current land. This name should exist in .pvc/land/<name>
where the current tree lives
Each command can be hooked with perl snippets just placing them into the .pvc/hook/(pre)<cmd> file.
For example:
$ echo 'for my $file (@arg) { unlink $file; }' > .pvc/hook/rm
This another example will send a mail every time you commit:
$ echo 'system("pvc.mail -smtp -diff mylist\@server.com | \
nc mail.server.com 25");' > .pvc/hook/commit
You can get a report of the commit by typing:
$ echo 'system("pvc report 0");' >> .pvc/hook/commit
Automatize a reset when changing between lands:
$ echo '
$resetting=1;
if ($arg[0]) { if (`pvc diff`) {
print "Local changes found. Not resetting.\n" if (`pvc diff`);
$resetting=0;
}}
' >.pvc/hook/preland
$ echo 'system("pvc reset") if ($resetting);' > .pvc/hook/land
By default 'pvc init' creates some hooks. Advanced users should probably remove them to avoid unexpected actions.
0.1 : 2007-04-09 0.2 : 2007-04-14 0.3 : 2007-04-22 0.4 : 2007-06-02 0.5 : 2007-06-23 0.6 : 2007-08-13
pancake <pancake@youterm.com>