]> git.madduck.net Git - code/myrepos.git/blob - lib/unison

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

For the checkout command, MR_REPO was set to the name of the parent directory of...
[code/myrepos.git] / lib / unison
1 # This allows using unison as a "revison control system" with mr.
2
3 # You need to configure unison by setting up files in ~/.unison named
4 # the same as the basenames of the directories you want to sync, and
5 # containing unison configuration to sync them.
6 #
7 # By default commit will be interactive; you can set batch mode in the
8 # config file to disable this. All other commands use batch mode by
9 # default.
10
11 # To make mr use this file, add a line like this inside the [DEFAULT]
12 # section of your ~/.mrconfig
13 #include = cat /usr/share/mr/unison
14
15 # And an example repo using it would look something like:
16 #[music]
17 #unison_test = true
18 #checkout = unison_checkout music
19
20 lib =
21         # The name of the directory containing the repo is assumed to
22         # match that of a unison config file.
23         unison_config() {
24                 basename "$MR_REPO"
25         }
26         unison_batch() {
27                 unison -batch $(unison_config)
28         }
29         unison_checkout() {
30                 mkdir "$1" && cd "$1" && unison -batch "$1"
31         }
32
33 unison_update   = unison_batch
34 unison_push     = unison_batch
35 unison_commit   = unison $(unison_config)
36
37 # vim:sw=8:sts=0:ts=8:noet