Skip to content
flock(1) locks files
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
config config: update symlinks Dec 18, 2015
man added long options, -E and —-verbose, changed spaces to tabs, possibl… Sep 15, 2018
src Merge pull request #20 from jayjlawrence/master Oct 19, 2018
t Add testing on -c omission, and locality Nov 30, 2016
.gitignore .gitignore: sort & cleanup Dec 18, 2015
LICENSE.md LICENSE.md: update copyright Dec 18, 2015
Makefile.am Makefile.am: remove unused-result warning to support Centos 6.7 sourc… Dec 18, 2015
README.md
autogen.sh initial commit Aug 17, 2014
configure.ac README.md, configure.ac: bump version to 0.2.3 Dec 18, 2015

README.md

flock(1)

flock(1) locks files

The simplest thing that could possibly work

To exclusively lock /tmp/my.lock while running the utility echo "hello, world!":

flock /tmp/my.lock echo "hello, world!"

Installing

Mac OS X Homebrew:

brew tap discoteq/discoteq
brew install flock

From source:

FLOCK_VERSION=0.2.3
wget https://github.com/discoteq/flock/releases/download/v${FLOCK_VERSION}/flock-${FLOCK_VERSION}.tar.xz
xz -dc flock-${FLOCK_VERSION}.tar.xz | tar -x
cd flock-${FLOCK_VERSION}
./configure
make
make install

Wait, isn't there already a flock(1)?

Yep, it's part of util-linux.

What makes discoteq flock(1) different is:

  • Support for latest stable Linux (Debian & CentOS), Illumos (OmniOS & SmartOS), Darwin & FreeBSD
  • Testing for all major features and edge conditions
  • ISC license
  • Public access to source history and bug tracking

Project Principles

  • Community: If a newbie has a bad time, it's a bug.
  • Software: Make it work, then make it right, then make it fast.
  • Technology: If it doesn't do a thing today, we can make it do it tomorrow.

Contributing

Got an idea? Something smell wrong? Cause you pain? Or lost seconds of your life you'll never get back?

All contributions are welcome: ideas, patches, documentation, bug reports, complaints, and even something you drew up on a napkin.

Programming is not a required skill. Whatever you've seen about open source and maintainers or community members saying "send patches or die" - you will not see that here.

It is more important to me that you are able to contribute.

Creating a new issue is probably the fastest way to get something fixed, but feel free to contact me via email (joseph@josephholsten.com), in IRC or however you can.

There's no wrong way to file a bug report, but I'll be able to help fastest if you can describe:

  • what you did
  • what you expected to happen
  • what actually happened

(Some of the above was repurposed with <3 from logstash)

You can’t perform that action at this time.