1. Home
  2. Developer tools
  3. Linux Command Builder

Linux Command Builder

Get the flags right for the five commands people look up most, without reading the man pages each time.

Free, no sign-up. Runs in your browser: nothing is uploaded.

How to use Linux Command Builder

  1. Pick tar, find, grep, sed or awk.
  2. Fill in the options.
  3. Copy the command and read the explanation before running it.

Features

  • tar: create, extract or list with gzip, bzip2, xz or zstd, excludes and --strip-components
  • find: name, type, size, age, depth, pruned folders, -exec, xargs or -delete
  • grep: recursive, case, whole word, invert, context and include/exclude
  • sed: in-place with GNU or BSD syntax and an automatic safe delimiter
  • awk: columns, filters and sums

Supported formats

Input

  • Form input

You get

  • Copied text

Private by design

Everything you enter is processed by your browser on this device. Nothing is sent to openWorkstand or anyone else, so the Linux Command Builder is safe for private and work data. After you have used it once while online, it also works without an internet connection. How local processing works

Good to know

  • Commands follow GNU tools; BSD and macOS versions differ in some flags.

Guide

Building tar, find, grep, sed and awk commands correctly

Five commands do most of the everyday text and file work on Linux and macOS: tar packs and unpacks archives, find locates files, grep searches inside them, sed edits text and awk works with columns. Each has dozens of options and a few traps, so people search for the same examples again and again. This builder fills in the flags from a form, quotes arguments safely and explains in plain English what the command will do.

tar

Choose create, extract or list, and a compression: gzip for .tar.gz, bzip2 for .tar.bz2, xz for .tar.xz or zstd for .tar.zst. When creating, list the files and folders and any patterns to exclude, such as node_modules; each becomes an --exclude option. When extracting, -C chooses the target folder and --strip-components drops leading folders from the archive’s paths, useful for release tarballs that wrap everything in a versioned folder.

find

Pick a start folder and combine tests: name patterns (case-sensitive or not), type, size above or below a value, and age in days with -mtime, where +30 means older than 30 days. A folder to skip is written with the -path … -prune -o idiom so find does not even descend into it. Then decide what happens with the matches: print them, count them, run a command on them in batches with -exec … {} + or xargs -0, or delete them.

grep

Search a pattern recursively, case-insensitively, as whole words or inverted, as a fixed string or an extended regular expression, with line numbers, only file names or counts per file, and context lines around each match. --include limits the search to file types and --exclude-dir skips folders such as .git. The builder adds -- before the pattern, so a pattern that starts with a dash is not mistaken for an option.

sed and awk

For sed’s substitute command, the builder picks a delimiter that does not occur in your text, so replacing paths needs no escaping, and escapes &, which sed would otherwise replace with the matched text. In-place editing has two spellings: GNU sed on Linux takes -i.bak, BSD sed on macOS needs -i '.bak' or -i ''. For awk, set the field separator, the columns to print, a filter on one column and whether to skip a header line, or sum a column instead.

Worked examples

The default find command is find /var/log -type f -name '*.log' -mtime +30 -print, which lists log files older than 30 days. The tar defaults give tar -czf backup-2026-10-30.tar.gz --exclude=node_modules --exclude='*.log' site config. The sed defaults produce sed -i.bak 's|http://example.com|https://example.com|g' index.html, using | because the text contains slashes. For awk, awk -F , 'NR > 1 && $3 > 100 { print $1, $3 }' orders.csv prints the first and third columns of rows whose third column is above 100.

Habits that prevent accidents

Run find with Print before switching to Delete, and sed without -i before editing in place; the builder warns about both. Keep the backup suffix on in-place edits until you trust the command. Read the explanation line under each command: if it does not describe what you meant, the flags are wrong.

Checked against the current version of the Linux Command Builder on .

Frequently asked questions

Why does find need quotes around *.log?

Without quotes, the shell expands *.log against the current folder before find runs. If one log file sits there, find receives that single name instead of the pattern and only looks for files called exactly that.

Can I preview what a sed command will change?

Run it without -i first: sed prints the edited text to the terminal and leaves the file alone. Pipe it through diff, as in sed … file | diff file -, to see only the changed lines before committing to the in-place edit.

Why does sed -i fail on macOS?

BSD sed on macOS requires a backup suffix argument after -i, even an empty one (sed -i '' …), while GNU sed on Linux takes it attached (-i.bak) or not at all. Choose the macOS variant in the sed options.

What is the difference between find -exec {} + and xargs?

Both run the command with many paths at once. -exec … {} + is built into find; xargs -0 with find -print0 adds options such as running jobs in parallel with -P. Both handle spaces in file names when used this way.

Keep working with the result

openWorkstand also includes a free workspace with documents, spreadsheets, tasks, projects and a calendar that save to a folder on your computer.