1 /* link.c - hardlink a file
3 * Copyright 2011 Rob Landley <rob@landley.net>
5 * See http://opengroup.org/onlinepubs/9699919799/utilities/link.html
7 USE_LINK(NEWTOY(link, "<2>2", TOYFLAG_USR|TOYFLAG_BIN))
13 usage: link FILE NEWLINK
15 Create hardlink to a file.
22 if (link(toys.optargs[0], toys.optargs[1]))
23 perror_exit("couldn't link '%s' to '%s'", toys.optargs[1],