From 3a511922b9e6fd25aefedb72e35a4afc1cc024a5 Mon Sep 17 00:00:00 2001 From: Luke Shumaker Date: Tue, 14 Jul 2009 14:44:50 -0400 Subject: copy-edit HACKING file --- HACKING | 87 +++++++++++++++++++++++++++++++++-------------------------------- README | 2 -- TODO | 11 --------- 3 files changed, 44 insertions(+), 56 deletions(-) delete mode 100644 TODO diff --git a/HACKING b/HACKING index 6fb4597..062814a 100644 --- a/HACKING +++ b/HACKING @@ -59,58 +59,59 @@ executable, and the file you call when you type `rvs' is just a wrapper for them. ----------------------------------------------------------------------- ------ The rest is copy/pasted, and still needs to be copy-edited.----- ----------------------------------------------------------------------- - - commit actually does take a parameter. It can commit any file or - directory. It works as it does because if no file is given, it - defaults to ./. If it is given a directory (as it is by - default), it loops through each file in the directory and - commits them (by calling itself). In order to actually commit a - file or directory it calls rvs commit.type where type is the - standard unix file-type code: - - block (buffered) special b - character (unbuffered) special c - directory d - named pipe (FIFO) p - regular file f - symbolic link l - socket s - door (Solaris only) D - - As you probably noticed, only directories and regular files have - been implemented in this release. get works in much the same - way. If you implement any other file types, save the commit and - get functions accordingly, and uncomment the line in - source/rvs-corecommit. Any commit function takes a filename as - an argument and outputs the according commit id to stdout. Any - get function takes the commit id as an argument and uses stdout - only if verbose, or to report errors. So the modules communicate - via pipes, which is generally considered bad-design, and - libraries should be used. I deliberatly broke this because this - way: + The wrapper is quite simple in mechanism. It simply checks if + `$$libdir$$/COMMAND_NAME' exists, and if so, runs that file. + + The `rvs commit' command is also quite simple in design. It takes a + single argument; the file to commit. If no target is specified, it + defaults to `./'. It checks which type of file the target is, and + runs `rvs commit.FILE_CODE TARGET'. The file codes are as follows: + + block (buffered) special b + character (unbuffered) special c + directory d + named pipe (FIFO) p + regular file f + symbolic link l + socket s + door (Solaris only) D + + As you probably noticed (if you've looked at the blueprints or + source files), only directories and regular files have been + implemented as of rvs 0.6.1. + + After `rvs commit' has done this, it creates a meta-file for that + commit. The meta file contains author, copyright owner, licence + data, file permissions, timestamps, etc. The id of the meta-file + is written to stdout, and used to later check out that commit + + get works in much the same way as commit, only it reads the file + type from the meta-file, then runs `rvs get.FILE_CODE COMMIT_ID'. + + If you implement any other file types, save the commit and get + functions in the propper locations. + + Any commit function should take a filename as an argument and + output the according commit id to stdout. + + Any get function should take the commit id as an argument and + uses stdout only if verbose, or to report errors. + + To summarize, the modules are separate programs and communicate via + pipes, which is generally considered bad-design, and libraries + should be used instead. I deliberatly broke this because: 1. incompatible licences can be used for different modules 2. modules can be added/removed on the fly - 3. one can use any lanugage to write new modules, without + 3. one can use any language to write new modules, without having to worry about bindings - known bugs - - * borks on files with the newline character. The smart thing - to do would be to escape all speacial characters. - Files to be changed: - * source/rvs-core/commit - * source/rvs-core/commit.d - * source/rvs-core/get.d - I have set up bazaar repository at Launchpad: https://launchpad.net/rvs Only until rvs becomes self-hosting. - If anyone needs any help, let me know. + If anyone needs any help, let me know, either via email, or via + Launchpad, I'll be happy to help! ~ Luke Shumaker Happy Hacking! diff --git a/README b/README index 4349f61..cf69e74 100644 --- a/README +++ b/README @@ -91,6 +91,4 @@ building ~ Luke Shumaker Happy Hacking! -([$prefix]/[$bindir]/rvs) but option handling. - diff --git a/TODO b/TODO deleted file mode 100644 index a8a1d78..0000000 --- a/TODO +++ /dev/null @@ -1,11 +0,0 @@ -* implement other unix file types (see the HACKING file) -* add real option handling (code from another project is - provided in source/rvs) -* write real documentation -* implment a parent/child tree - * implement branch ids (NOTE: wch should be used to refer - to the latest commit in a branch) -* implement tags -* owner/filepermissions/timestamps -* usernames/author - -- cgit v1.1-4-g5e80