Find (Windows)

Last updated
find
Developer(s) Microsoft, IBM, DR, Datalight, Novell, Jim Hall, ReactOS Contributors
Initial releaseMarch 1983;40 years ago (1983-03)
Written in MS-DOS: x86 assembly language
FreeDOS, ReactOS: C
Operating system MS-DOS, PC DOS, FlexOS, SISNE plus, DR DOS, ROM-DOS, FreeDOS, 4690 OS, Windows, OS/2, eComStation, ArcaOS, ReactOS
Platform Cross-platform
Type Command
License MS-DOS: MIT
FreeDOS, ReactOS: GPLv2+

In computing, find is a command in the command-line interpreters (shells) of a number of operating systems. It is used to search for a specific text string in a file or files. The command sends the specified lines to the standard output device. [1] [2]

Contents

Overview

The find command is a filter to find lines in the input data stream that contain or don't contain a specified string and send these to the output data stream. It does not support wildcard characters. [3]

The command is available in DOS, [4] Digital Research FlexOS, [5] IBM/Toshiba 4690 OS, [6] IBM OS/2, [7] Microsoft Windows, [8] and ReactOS. [9] On MS-DOS, the command is available in versions 2 and later. [10] DR DOS 6.0 [11] and Datalight ROM-DOS [12] include an implementation of the find command. The FreeDOS version was developed by Jim Hall and is licensed under the GPL. [13]

The Unix command find performs an entirely different function, analogous to forfiles on Windows. The rough equivalent to the Windows find is the Unix grep . [14]

Syntax

FIND [/V] [/C] [/N] [/I] "string" [[drive:][path]filename[...]] 

Arguments:

Flags:

Note: If a pathname is not specified, FIND searches the text typed at the prompt or piped from another command.

Examples

C:\>find "keyword"< inputfilename > outputfilename 
C:\>find /V "any string" FileName 

See also

Related Research Articles

Edlin is a line editor, and the only text editor provided with early versions of IBM PC DOS, MS-DOS and OS/2. Although superseded in MS-DOS 5.0 and later by the full-screen MS-DOS Editor, and by Notepad in Microsoft Windows, it continues to be included in the 32-bit versions of current Microsoft operating systems.

dir (command) Directory information command on various operating systems

In computing, dir (directory) is a command in various computer operating systems used for computer file and directory listing. It is one of the basic commands to help navigate the file system. The command is usually implemented as an internal command in the command-line interpreter (shell). On some systems, a more graphical representation of the directory structure can be displayed using the tree command.

mkdir Directory creation command on various operating systems

The mkdir command in the Unix, DOS, DR FlexOS, IBM OS/2, Microsoft Windows, and ReactOS operating systems is used to make a new directory. It is also available in the EFI shell and in the PHP scripting language. In DOS, OS/2, Windows and ReactOS, the command is often abbreviated to md.

In computing, touch is a command used to update the access date and/or modification date of a computer file or directory. It is included in Unix and Unix-like operating systems, TSC's FLEX, Digital Research/Novell DR DOS, the AROS shell, the Microware OS-9 shell, and ReactOS. The command is also available for FreeDOS and Microsoft Windows.

more (command) Terminal pager available on various operating systems

In computing, more is a command to view the contents of a text file one screen at a time. It is available on Unix and Unix-like systems, DOS, Digital Research FlexOS, IBM/Toshiba 4690 OS, IBM OS/2, Microsoft Windows and ReactOS. Programs of this sort are called pagers. more is a very basic pager, originally allowing only forward navigation through a file, though newer implementations do allow for limited backward movement.

In computing, tee is a command in command-line interpreters (shells) using standard streams which reads standard input and writes it to both standard output and one or more files, effectively duplicating its input. It is primarily used in conjunction with pipes and filters. The command is named after the T-splitter used in plumbing.

<span class="mw-page-title-main">File Compare</span> Command-line program that compares multiple files

In computing, fc is a command-line program in DOS, IBM OS/2 and Microsoft Windows operating systems, that compares multiple files and outputs the differences between them. It is similar to the Unix commands comm, cmp and diff.

<span class="mw-page-title-main">ATTRIB</span>

In computing, ATTRIB is a command in Intel ISIS-II, DOS, IBM OS/2, Microsoft Windows and ReactOS that allows the user to change various characteristics, or "attributes" of a computer file or directory. The command is also available in the EFI shell.

<span class="mw-page-title-main">TYPE (DOS command)</span>

In computing, type is a command in various command-line interpreters (shells) such as COMMAND.COM, cmd.exe, 4DOS/4NT and Windows PowerShell used to display the contents of specified files on the computer terminal. The analogous Unix command is cat.

del (command) Command in various operating systems

In computing, del is a command in command-line interpreters (shells) such as COMMAND.COM, cmd.exe, 4DOS, NDOS, 4OS2, 4NT and Windows PowerShell. It is used to delete one or more files or directories from a file system.

<span class="mw-page-title-main">PRINT (command)</span> Computing command

In computing, the print command provides single-user print spooling capability in a number of operating systems. It is roughly similar to that provided by the UNIX System V lp and BSD lpr print spooler systems.

In computing, label is a command included with some operating systems. It is used to create, change, or delete a volume label on a logical drive, such as a hard disk partition or a floppy disk. Used without parameters, label changes the current volume label or deletes the existing label.

help (command) Command in various command line shells

In computing, help is a command in various command line shells such as COMMAND.COM, cmd.exe, Bash, qshell, 4DOS/4NT, Windows PowerShell, Singularity shell, Python, MATLAB and GNU Octave. It provides online information about available commands and the shell environment.

copy (command)

In computing, copy is a command in various operating systems. The command copies computer files from one directory to another.

format (command)

In computing, format, a command-line utility that carries out disk formatting. It is a component of various operating systems, including 86-DOS, MS-DOS, IBM PC DOS and OS/2, Microsoft Windows and ReactOS.

choice (command)

In computing, choice is a command that allows for batch files to prompt the user to select one item from a set of single-character choices. It is available in a number of operating system command-line shells.

In computing, diskcopy is a command used on a number of operating systems for copying the complete contents of a diskette to another diskette.

In computing, findstr is a command in the command-line interpreters (shells) of Microsoft Windows and ReactOS. It is used to search for a specific text string in computer files.

In computing, recover is a primitive file system error recovery utility included in MS-DOS / IBM PC DOS versions prior to DOS 6.0 and a number of other operating systems.

replace (command)

In computing, replace is a command that is used to replace one or more existing computer files or add new files to a target directory. Files with a hidden or system attribute set cannot be replaced using replace. The command lists all files that are replaced.

References

  1. Paterson, Tim (2013-12-19) [1983]. "Microsoft DOS V1.1 and V2.0: /msdos/v20source/FIND.ASM". Computer History Museum, Microsoft . Retrieved 2015-10-01.
  2. Shustek, Len (2014-03-24). "Microsoft MS-DOS early source code". Software Gems: The Computer History Museum Historical Source Code Series. Retrieved 2015-10-01.
  3. "Find - Search for text - Windows CMD - SS64.com". ss64.com.
  4. Jamsa, Kris A. (1993), DOS: The Complete Reference, Osborne McGraw-Hill, p. 206, ISBN   0078819040.
  5. "FlexOS User's Guide" (PDF). www.bitsavers.org. 1986. Archived from the original (PDF) on 2019-09-25. Retrieved 2020-09-14.
  6. "Users guide". archive.org. Retrieved 2020-09-14.
  7. "JaTomes Help - OS/2 Commands". Archived from the original on 2019-04-14. Retrieved 2019-07-20.
  8. "Find". Archived from the original on 2017-08-26. Retrieved 2017-08-26.
  9. "reactos/reactos". GitHub. 3 January 2022.
  10. Wolverton, Van (2003). Running MS-DOS Version 6.22 (20th Anniversary Edition), 6th Revised edition. Microsoft Press. ISBN   0-7356-1812-7.
  11. DR DOS 6.0 User Guide Optimisation and Configuration Tips
  12. "Datalight ROM-DOS User's Guide" (PDF). www.datalight.com.
  13. "ibiblio.org FreeDOS Package -- find (FreeDOS Base)". www.ibiblio.org.
  14. "Equivalent of UNIX Grep command in Dos/Windows". January 26, 2009.

Further reading