43f has been tested on Mac OS X, Linux, and OpenBSD. It requires Bash 3+ and Sebastian Freundt's Dateutils for calculating relative dates. These should be installed prior to following the installation instructions below.
Installation is currently a manual process, but fairly straightforward:
-
Clone the
43fGit repository:git clone https://github.com/morgant/43f.git -
Change to the
43fGit repository directory:cd 43f -
Optional, but suggested: run the test suite as follows (requires dateutils &
roundup):roundup test/*-test.sh -
Install
43fand the default configuration file into/usr/local/:./configure sudo make install
-
Copy the newly installed
/usr/local/etc/43f.conf.defaultfile to/usr/local/etc/43f.confand edit to suit your needs (esp. therepositoryvalue which you'll need for the next step). -
Initialize the
43frepository (replacing/path/to/repositorywith the path to the directory where you would like43fto store & manage files):43f init /path/to/repository -
If you will use
launchdto run43f's nightly storage management process (highly suggested):sudo launchctl load /Library/LaunchDaemons/com.makkintosshu.43f.plistOtherwise, if you prefer to use cron, then edit your preferred crontab (replacing
usernamewith the name of the user who you'd like43fto be run by):sudo crontab -u username -eAnd pasting in the following:
0 0 * * * /usr/local/bin/43f runMake sure that the
PATHenvironment variable is also set in the crontab and includes the path to Dateutils (usually/usr/local/bin), e.g.:PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/local/sbin -
That should do it. You should now be able to start storing files and/or directories in the daily and/or monthly directories within your
43frepository file structure (there are eventoday,yesterday,sunday,monday,tuesday,wednesday,thursday,friday, andsaturdaysymlinks for your convenience).
If you would like to install the 43f configuration in a different location
than the default of /usr/local/etc, you may do so, but will need to modify
either the com.makkintosshu.43f.plist file or the line in your crontab
(Step 7 in the "BASIC INSTALLATION" instructions) to explicitly specify the
configuration file with the -c option, for example:
/usr/local/bin/43f -c /path/to/config/43f.conf run
Please note that, if using launchd, the launchd.plist syntax requires that
each argument be specified in a different string in the ProgramArguments
dictionary, so:
<key>ProgramArguments</key>
<array>
<string>/usr/local/bin/43f</string>
<string>run</string>
</array>
Would need to become:
<key>ProgramArguments</key>
<array>
<string>/usr/local/bin/43f</string>
<string>-c</string>
<string>/path/to/config/43f.conf</string>
<string>run</string>
</array>