www.delorie.com/gnu/docs/textutils/coreutils.html   search  
 
Buy GNU books!


GNU Core-utils

[Top] [Contents] [Index] [ ? ]

GNU Core-utils

@insertcopying

1. Introduction  Caveats, overview, and authors.
2. Common options  
3. Output of entire files  cat tac nl od
4. Formatting file contents  fmt pr fold
5. Output of parts of files  head tail split csplit
6. Summarizing files  wc sum cksum md5sum
7. Operating on sorted files  sort uniq comm ptx tsort
8. Operating on fields within a line  cut paste join
9. Operating on characters  tr expand unexpand
10. Directory listing  ls dir vdir d v dircolors
11. Basic operations  cp dd install mv rm shred
12. Special file types  ln mkdir rmdir mkfifo mknod
13. Changing file attributes  chgrp chmod chown touch
14. Disk usage  df du stat sync
15. Printing text  echo printf yes
16. Conditions  false true test expr
17. Redirection  tee
18. File name manipulation  dirname basename pathchk
19. Working context  pwd stty printenv tty
20. User information  id logname whoami groups users who
21. System context  date uname hostname
22. Modified command invocation  chroot env nice nohup su
23. Process control  kill
24. Delaying  sleep
25. Numeric operations  factor seq
26. File permissions  Access modes.
27. Date input formats  Specifying date strings.
28. Opening the Software Toolbox  The software tools philosophy.
A. GNU Free Documentation License  The license for this documentation.
Index  General index.

 -- The Detailed Node Listing ---

Common Options

2.1 Backup options  
2.2 Block size  
2.3 Target directory  
2.4 Trailing slashes  
2.5 Standards conformance  

Output of entire files

3.1 cat: Concatenate and write files  Concatenate and write files.
3.2 tac: Concatenate and write files in reverse  Concatenate and write files in reverse.
3.3 nl: Number lines and write files  Number lines and write files.
3.4 od: Write files in octal or other formats  Write files in octal or other formats.

Formatting file contents

4.1 fmt: Reformat paragraph text  Reformat paragraph text.
4.2 pr: Paginate or columnate files for printing  Paginate or columnate files for printing.
4.3 fold: Wrap input lines to fit in specified width  Wrap input lines to fit in specified width.

Output of parts of files

5.1 head: Output the first part of files  Output the first part of files.
5.2 tail: Output the last part of files  Output the last part of files.
5.3 split: Split a file into fixed-size pieces  Split a file into fixed-size pieces.
5.4 csplit: Split a file into context-determined pieces  Split a file into context-determined pieces.

Summarizing files

6.1 wc: Print byte, word, and line counts  Print byte, word, and line counts.
6.2 sum: Print checksum and block counts  Print checksum and block counts.
6.3 cksum: Print CRC checksum and byte counts  Print CRC checksum and byte counts.
6.4 md5sum: Print or check message-digests  Print or check message-digests.

Operating on sorted files

7.1 sort: Sort text files  Sort text files.
7.2 uniq: Uniquify files  Uniquify files.
7.3 comm: Compare two sorted files line by line  Compare two sorted files line by line.
7.6 ptx: Produce permuted indexes  Produce a permuted index of file contents.
7.4 tsort: Topological sort  Topological sort.

ptx: Produce permuted indexes

7.6.1 General options  Options which affect general program behavior.
7.6.2 Charset selection  Underlying character set considerations.
7.6.3 Word selection and input processing  Input fields, contexts, and keyword selection.
7.6.4 Output formatting  Types of output format, and sizing the fields.
7.6.5 The GNU extensions to ptx  

Operating on fields within a line

8.1 cut: Print selected parts of lines  Print selected parts of lines.
8.2 paste: Merge lines of files  Merge lines of files.
8.3 join: Join lines on a common field  Join lines on a common field.

Operating on characters

9.1 tr: Translate, squeeze, and/or delete characters  Translate, squeeze, and/or delete characters.
9.2 expand: Convert tabs to spaces  Convert tabs to spaces.
9.3 unexpand: Convert spaces to tabs  Convert spaces to tabs.

tr: Translate, squeeze, and/or delete characters

9.1.1 Specifying sets of characters  
9.1.2 Translating  Changing one characters to another.
9.1.3 Squeezing repeats and deleting  
9.1.4 Warning messages  

Directory listing

10.1 ls: List directory contents  List directory contents
10.2 dir: Briefly list directory contents  Briefly list directory contents
10.3 vdir: Verbosely list directory contents  Verbosely list directory contents
10.4 dircolors: Color setup for ls  Color setup for ls

ls:  List directory contents

10.1.1 Which files are listed  
10.1.2 What information is listed  
10.1.3 Sorting the output  
10.1.4 More details about version sort  
10.1.5 General output formatting  
10.1.7 Formatting the file names  

Basic operations

11.1 cp: Copy files and directories  Copy files and directories
11.2 dd: Convert and copy a file  Convert and copy a file
11.3 install: Copy files and set attributes  Copy files and set attributes
11.4 mv: Move (rename) files  Move (rename) files
11.5 rm: Remove files or directories  Remove files or directories
11.6 shred: Remove files more securely  Remove files more securely

Special file types

12.1 link: Make a hard link via the link syscall  Make a hard link via the link syscall
12.2 ln: Make links between files  Make links between files
12.3 mkdir: Make directories  Make directories
12.4 mkfifo: Make FIFOs (named pipes)  Make FIFOs (named pipes)
12.5 mknod: Make block or character special files  Make block or character special files
12.6 rmdir: Remove empty directories  Remove empty directories
12.7 unlink: Remove files via the unlink syscall  Remove files via unlink syscall

Changing file attributes

13.1 chown: Change file owner and group  Change file owner and group
13.2 chgrp: Change group ownership  Change group ownership
13.3 chmod: Change access permissions  Change access permissions
13.4 touch: Change file timestamps  Change file timestamps

Disk usage

14.1 df: Report filesystem disk space usage  Report filesystem disk space usage
14.2 du: Estimate file space usage  Estimate file space usage
14.3 stat: Report file or filesystem status  Report file or filesystem status
14.4 sync: Synchronize data on disk with memory  Synchronize data on disk with memory

Printing text

15.1 echo: Print a line of text  Print a line of text
15.2 printf: Format and print data  Format and print data
15.3 yes: Print a string until interrupted  Print a string until interrupted

Conditions

16.1 false: Do nothing, unsuccessfully  Do nothing, unsuccessfully
16.2 true: Do nothing, successfully  Do nothing, successfully
16.3 test: Check file types and compare values  Check file types and compare values
16.4 expr: Evaluate expressions  Evaluate expressions

test: Check file types and compare values

16.3.1 File type tests  
16.3.2 Access permission tests  
16.3.3 File characteristic tests  
16.3.4 String tests  
16.3.5 Numeric tests  

expr: Evaluate expression

16.4.1 String expressions  + : match substr index length
16.4.2 Numeric expressions  + - * / %
16.4.3 Relations for expr  | & < <= = == != >= >
16.4.4 Examples of using expr  

Redirection

17.1 tee: Redirect output to multiple files  Redirect output to multiple files

File name manipulation

18.1 basename: Strip directory and suffix from a file name  Strip directory and suffix from a file name
18.2 dirname: Strip non-directory suffix from a file name  Strip non-directory suffix from a file name
18.3 pathchk: Check file name portability  Check file name portability

Working context

19.1 pwd: Print working directory  Print working directory
19.2 stty: Print or change terminal characteristics  Print or change terminal characteristics
19.3 printenv: Print all or some environment variables  Print all or some environment variables
19.4 tty: Print file name of terminal on standard input  Print file name of terminal on standard input

stty: Print or change terminal characteristics

19.2.1 Control settings  
19.2.2 Input settings  
19.2.3 Output settings  
19.2.4 Local settings  
19.2.5 Combination settings  
19.2.6 Special characters  
19.2.7 Special settings  

User information

20.1 id: Print real and effective uid and gid  Print real and effective uid and gid
20.2 logname: Print current login name  Print current login name
20.3 whoami: Print effective user id  Print effective user id
20.4 groups: Print group names a user is in  Print group names a user is in
20.5 users: Print login names of users currently logged in  Print login names of users currently logged in
20.6 who: Print who is currently logged in  Print who is currently logged in

System context

21.1 date: Print or set system date and time  Print or set system date and time
21.2 uname: Print system information  Print system information
21.3 hostname: Print or set system name  Print or set system name
21.4 hostid: Print numeric host identifier.  Print numeric host identifier.

date: Print or set system date and time

21.1.1 Time directives  
21.1.2 Date directives  
21.1.3 Literal directives  
21.1.4 Padding  
21.1.5 Setting the time  
21.1.6 Options for date  
21.1.7 Examples of date  

Modified command invocation

22.1 chroot: Run a command with a different root directory  Run a command with a different root directory
22.2 env: Run a command in a modified environment  Run a command in a modified environment
22.3 nice: Run a command with modified scheduling priority  Run a command with modified scheduling priority
22.4 nohup: Run a command immune to hangups  Run a command immune to hangups
22.5 su: Run a command with substitute user and group id  Run a command with substitute user and group id

Process control

23.1 kill: Send a signal to processes  Sending a signal to processes.

Delaying

24.1 sleep: Delay for a specified time  Delay for a specified time

Numeric operations

25.1 factor: Print prime factors  Print prime factors
25.2 seq: Print numeric sequences  Print numeric sequences

File permissions

26.1 Structure of File Permissions  
26.2 Symbolic Modes  Mnemonic permissions representation
26.3 Numeric Modes  Permissions as octal numbers

Date input formats

27.1 General date syntax  
27.2 Calendar date items  
27.3 Time of day items  
27.4 Time zone items  
27.5 Day of week items  
27.6 Relative items in date strings  
27.7 Pure numbers in date strings  
27.8 Authors of getdate  

Opening the software toolbox

Toolbox Introduction  Toolbox introduction
I/O Redirection  I/O redirection
The who Command  The who command
The cut Command  The cut command
The sort Command  The sort command
The uniq Command  The uniq command
Putting the Tools Together  Putting the tools together

GNU Free Documentation License

ADDENDUM: How to use this License for your documents  


  webmaster     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003