fc (Unix)
fc
is a standard program on Unix and Unix-like operating systems that lists, edits and reexecutes commands previously entered to an interactive shell. fc is a builtin command in the Bash and Zsh shells and is an initialism for "fix command". It is particularly helpful for editing complex, multi-line commands. The editor can be specified by setting the EDITOR (changes the default editor) or the FCEDIT environment variable.
Operating system | Unix, Unix-like, Inferno |
---|---|
Type | Command |
Examples
$ fc -l
1001 ls
$ fc -s 1001
ls
$ fc
[Change 'ls' to 'ls -la' in editor and exit]
ls -la
...
gollark: ... is that *better*? It seems worse.
gollark: So it calculates the length in the `split` thing itself, then uses that?
gollark: OCAmuletâ„¢.
gollark: Hmm.
gollark: So what connectivity does your *desktop* have?
External links
- : process the command history list – Commands & Utilities Reference, The Single UNIX Specification, Issue 7 from The Open Group
This article is issued from Wikipedia. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.