MCPcopy Create free account
hub / github.com/coreutils/coreutils / usage

Function usage

src/ln.c:414–510  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

412}
413
414void
415usage (int status)
416{
417 if (status != EXIT_SUCCESS)
418 emit_try_help ();
419 else
420 {
421 printf (_("\
422Usage: %s [OPTION]... [-T] TARGET LINK_NAME\n\
423 or: %s [OPTION]... TARGET\n\
424 or: %s [OPTION]... TARGET... DIRECTORY\n\
425 or: %s [OPTION]... -t DIRECTORY TARGET...\n\
426"),
427 program_name, program_name, program_name, program_name);
428 fputs (_("\
429In the 1st form, create a link to TARGET with the name LINK_NAME.\n\
430In the 2nd form, create a link to TARGET in the current directory.\n\
431In the 3rd and 4th forms, create links to each TARGET in DIRECTORY.\n\
432Create hard links by default, symbolic links with --symbolic.\n\
433By default, each destination (name of new link) should not already exist.\n\
434When creating hard links, each TARGET must exist. Symbolic links\n\
435can hold arbitrary text; if later resolved, a relative link is\n\
436interpreted in relation to its parent directory.\n\
437"), stdout);
438
439 emit_mandatory_arg_note ();
440
441 oputs (_("\
442 --backup[=CONTROL]\n\
443 make a backup of each existing destination file\n\
444"));
445 oputs (_("\
446 -b\n\
447 like --backup but does not accept an argument\n\
448"));
449 oputs (_("\
450 -d, -F, --directory\n\
451 allow the superuser to attempt to hard link directories,\n\
452 if supported by the system\n\
453"));
454 oputs (_("\
455 -f, --force\n\
456 remove existing destination files\n\
457"));
458 oputs (_("\
459 -i, --interactive\n\
460 prompt whether to remove destinations\n\
461"));
462 oputs (_("\
463 -L, --logical\n\
464 dereference TARGETs that are symbolic links\n\
465"));
466 oputs (_("\
467 -n, --no-dereference\n\
468 treat LINK_NAME as a normal file\n\
469 if it is a symbolic link to a directory\n\
470"));
471 oputs (_("\

Callers 1

mainFunction · 0.70

Calls 3

emit_mandatory_arg_noteFunction · 0.85
emit_backup_suffix_noteFunction · 0.85
emit_ancillary_infoFunction · 0.85

Tested by

no test coverage detected