slocate
Redhat系で使い慣れている「locate」をOS Xに入れてみる。
portで探してみたら、なんか「locate」の代わりに「slocate」というのが引っかかる。
$ port search locate
slocate sysutils/slocate 3.1 Secure Locate is a replacement for locate.
$ sudo port install slocate
- > Fetching slocate
- > Attempting to fetch slocate-3.1.tar.gz from http://slocate.trakker.ca/files/
- > Attempting to fetch slocate-3.1.tar.gz from http://fresh.t-systems-sfr.com/unix/src/misc/
- > Verifying checksum(s) for slocate
- > Extracting slocate
- > Applying patches to slocate
- > Configuring slocate
- > Building slocate with target all
- > Staging slocate into destroot
- > Installing slocate 3.1_1
slocate's database should be updated on a regular basis. In
/opt/local/etc/daily.slocate, you'll find some lines to put in
/etc/daily.local to update the database on a daily basis (for example).
If you want to disable the weekly update of the system's built-in locate,
edit the file /etc/weekly.
- > Activating slocate 3.1_1
- > Cleaning slocate
dbのupdateがupdatedbではなく、slocate -uになるみたい。