Gang Of Coders
Home
About Us
Contact Us
All Sed Solutions on Gang of Coders
Total of 180 Sed Solutions
How to delete from a text file, all lines that contain a specific string?
Shell
Sed
Text Parsing
In Place
How can I replace each newline (\n) with a space using sed?
Sed
How can I do a recursive find/replace of a string with awk or sed?
Bash
Sed
Awk
Replace
Bash tool to get nth line from a file
Bash
Shell
Unix
Awk
Sed
How can I remove the first line of a text file using bash/sed script?
Bash
Scripting
Sed
Find and replace in file and overwrite file doesn't work, it empties the file
Shell
Unix
Sed
Io Redirection
What is the difference between sed and awk?
Sed
Awk
Non greedy (reluctant) regex matching in sed?
Regex
Sed
Pcre
Greedy
Regex Greedy
Delete empty lines using sed
Linux
Unix
Sed
How to remove double-quotes in jq output for parsing json files in bash?
Bash
Awk
Sed
Jq
sed edit file in place
Unix
Sed
Solaris
Replace whole line containing a string using Sed
String
Shell
Sed
sed command with -i option failing on Mac, but works on Linux
Linux
Macos
Bash
Sed
Escape a string for a sed replace pattern
String
Sed
Escaping
Shell script - remove first and last quote (") from a variable
String
Bash
Shell
Unix
Sed
How can I output only captured groups with sed?
Regex
Sed
Replace comma with newline in sed on MacOS?
Macos
Unix
Sed
How to swap text based on patterns at once with sed?
Replace
Syntax
Sed
Delete specific line number(s) from a text file using sed?
Unix
Sed
Line Numbers
sed in-place flag that works both on Mac (BSD) and Linux
Linux
Macos
Sed
Bsd
Find and replace with sed in directory and sub directories
Linux
Command Line
Sed
Replace
Insert line after match using sed
Shell
Sed
Error when using 'sed' with 'find' command on OS X: "invalid command code ."
Bash
Macos
Sed
Find
How to use sed to replace only the first occurrence in a file?
Command Line
Sed
Text Processing
How to insert a text at the beginning of a file?
Linux
Bash
Sed
What are the differences between Perl, Python, AWK and sed?
Python
Perl
Sed
Awk
Language Comparisons
Environment variable substitution in sed
Linux
Unix
Shell
Sed
How to show only next line after the matched one?
Awk
Sed
Grep
Retrieve last 100 lines logs
Linux
Logging
Sed
Change multiple files
Sed
Command to get nth line of STDOUT
Bash
Shell
Sed
Stdout
Delete all lines beginning with a # from a file
Bash
Sed
RE error: illegal byte sequence on Mac OS X
Regex
Macos
Bash
Sed
Appending a line to a file only if it does not already exist
Linux
Sed
Terminal
sed fails with "unknown option to `s'" error
Sed
In-place edits with sed on OS X
Macos
File Io
Sed
In Place
How to remove the lines which appear on file B from another file A?
Linux
Shell
Sed
Diff
Grep
How to replace a whole line with sed?
Regex
Sed
How to use sed to remove the last n lines of a file
Linux
Bash
Shell
Sed
Insert a line at specific line number with sed or awk
Sed
Awk
How to merge every two lines into one from the command line?
Bash
Awk
Sed
Grep
How to replace an entire line in a text file by line number
Bash
Text
Replace
Sed
How to use sed/grep to extract text between two words?
String
Bash
Sed
Grep
How to grep for case insensitive string in a file?
Bash
Shell
Awk
Sed
Grep
How to delete duplicate lines in a file without sorting it in Unix
Unix
Shell
Scripting
Sed
Awk
Is there any sed like utility for cmd.exe?
Windows
Sed
Cmd
How can I delete a newline if it is the last character in a file?
Linux
Perl
Shell
Awk
Sed
sed one-liner to convert all uppercase to lowercase?
Regex
Sed
How to insert strings containing slashes with sed?
Sed
How do I remove newlines from a text file?
Linux
Bash
Scripting
Shell
Sed
sed: print only matching group
Regex
Sed
sed command with -i option (in-place editing) works fine on Ubuntu but not Mac
Linux
Macos
Sed
Bsd
Inplace Editing
Why does sed not replace all occurrences?
Bash
Sed
How can I strip first X characters from string using sed?
Bash
Shell
Sed
How to insert a newline in front of a pattern?
Shell
Sed
How to select lines between two marker patterns which may occur multiple times with awk/sed
Shell
Unix
Sed
Awk
Pattern Matching
What are the differences among grep, awk & sed?
Linux
Bash
Sed
Awk
Grep
How to pass a variable containing slashes to sed
Bash
Sed
In Bash, how do I add a string after each line in a file?
Linux
Bash
Unix
Sed
sed or awk: delete n lines following a pattern
Unix
Sed
Awk
Using sed, how do you print the first 'N' characters of a line?
Shell
Sed
Grep
sed whole word search and replace
Shell
Sed
Printing everything except the first field with awk
Awk
Sed
How to remove trailing whitespaces with sed?
Sed
Whitespace
how to parse a JSON String with jq (or other alternatives)?
Json
String
Sed
Escaping
Jq
sed error: "invalid reference \1 on `s' command's RHS"
Regex
Sed
Substitution
Changing all occurrences in a folder
Regex
Linux
Shell
Sed
Add text at the end of each line
Sed
Command Line-Interface
Preserve line endings
Windows
Sed
Why is sed not recognizing \t as a tab?
Regex
Bash
Sed
Replace a string in shell script using a variable
Unix
Shell
Sed
sed with literal string--not input file
Linux
Unix
Sed
Append file contents to the bottom of existing file in Bash
Bash
Sed
Awk
Append
How to extract text from a string using sed?
Regex
Bash
Sed
How to escape single quote in sed?
Sed
Escaping
Quote
How to extract string following a pattern with grep, regex or perl
Regex
Perl
Sed
Html Parsing
Text Extraction
How to use GNU sed on Mac OS 10.10+, 'brew install --default-names' no longer supported
Macos
Bash
Sed
Homebrew
Gnu
Have sed ignore non-matching lines
Sed
How do I delete all lines in a file starting from after a matching line?
Linux
Bash
Sed
Using sed to mass rename files
Bash
Shell
Sed
File Rename
The Concept of 'Hold space' and 'Pattern space' in sed
Linux
Sed
how to use sed, awk, or gawk to print only what is matched?
Regex
Unix
Sed
Awk
Gawk
The easiest way to replace white spaces with (underscores) _ in bash
Bash
Sed
Using sed and grep/egrep to search and replace
Regex
Sed
Grep
How to print the number of characters in each line of a text file
Shell
Unix
Sed
Awk
Turning multiple lines into one comma separated line
Linux
Perl
Unix
Sed
Awk
find difference between two text files with one item per line
Bash
File
Scripting
Sed
Awk
Case-insensitive search and replace with sed
Macos
Replace
Sed
Case Insensitive
Getting "sed error - illegal byte sequence" (in bash)
Bash
Sed
Using sed to delete all lines between two matching patterns
Regex
Sed
How to add to the end of lines containing a pattern with sed or awk?
Bash
Sed
Awk
How to remove all white spaces from a given text file
Linux
Bash
Sed
Recursively rename files using find and sed
Bash
Scripting
Sed
Find
Replace
sed insert line with spaces to a specific line
Linux
Bash
Sed
How do I escape slashes and double and single quotes in sed?
Bash
Sed
'+' (one or more occurrences) not working with 'sed' command
Macos
Bash
Sed
How can I remove the last character of a file in unix?
Linux
Bash
Unix
Sed
Insert multiple lines into a file after specified pattern using shell script
Linux
Bash
Shell
Sed
Awk
Delete the first five characters on any line of a text file in Linux with sed
Linux
Unix
Sed
Remove part of path on Unix
Shell
Unix
Scripting
Sed
sed delete lines not containing specific string
Sed
Using sed, Insert a line above or below the pattern?
Scripting
Sed
Awk
sed - Commenting a line matching a specific string AND that is not already commented out
Regex
Sed
How to print lines between two patterns, inclusive or exclusive (in sed, AWK or Perl)?
Shell
Perl
Awk
Sed
Pattern Matching
Command line: search and replace in all filenames matched by grep
Linux
Perl
Awk
Sed
Grep
How to find and replace all occurrences of a string recursively in a directory tree?
Sed
Find
Grep
Replace
How to use python regex to replace using captured group?
Python
Regex
Sed
Replace
sed plus sign doesn't work
Regex
Bash
Sed
Why doesn't `\d` work in regular expressions in sed?
Regex
Linux
Awk
Sed
Printing with sed or awk a line following a matching pattern
Awk
Sed
bash, extract string before a colon
Regex
String
Bash
Sed
Substring
sed substitution with Bash variables
Bash
Sed
Substitution
Replace newlines with literal \n
Regex
Sed
how to remove the first two columns in a file using shell (awk, sed, whatever)
Perl
Shell
Awk
Sed
Cut
Replace all whitespace with a line break/paragraph mark to make a word list
Regex
Sed
How to remove leading whitespace from each line in a file
Unix
Sed
Awk
Grep
Swap two columns - awk, sed, python, perl
Sed
Awk
Return value of sed for no match
Linux
Json
Sed
How to use sed to extract substring
Linux
Shell
Ubuntu
Xml Parsing
Sed
Using grep and sed to find and replace a string
Linux
Shell
Unix
Sed
Grep
How to decode URL-encoded string in shell?
Bash
Shell
Awk
Sed
Urldecode
Ansible playbook shell output
Shell
Sed
Ansible
How can I insert a tab character with sed on OS X?
Regex
Macos
Sed
How to replace a path with another path in sed?
Path
Sed
Csh
Is it possible to escape regex metacharacters reliably with sed
Regex
Sed
Can I use sed to manipulate a variable in bash?
Bash
Replace
Sed
How to use variables in a command in sed?
Unix
Sed
sed -i command for in-place editing to work with both GNU sed and BSD/OSX
Macos
Sed
Gnu
Inplace Editing
Replace whole line when match found with sed
Shell
Replace
Sed
Match
.bash_profile sed: \1 not defined in the RE
Sed
Homebrew
.Bash Profile
What's wrong with my lookahead regex in GNU sed?
Regex
Linux
Sed
Regex Lookarounds
How to remove a character at the end of each line in UNIX
Unix
Awk
Sed
How to use SED to find and replace URL strings with the "/" character in the targeted strings?
Bash
Sed
Escaping
Concatenate in bash the output of two commands without newline character
Regex
Bash
Sed
Pipe
Concatenation
Sed expression doesn't allow optional grouped string
Regex
Sed
Extract string from brackets
Bash
Sed
Convert line endings
Bash
Shell
Sed
Command Line
Dos2unix
Append line to /etc/hosts file with shell script
Linux
Bash
Shell
Ubuntu
Sed
Insert newline (\n) using sed
Bash
Sed
Freebsd
Easiest way to extract the urls from an html page using sed or awk only
Html
Regex
Bash
Sed
Awk
Can you mass edit all files returned in a grep?
Search
Vim
Command Line
Sed
Grep
Remove non-ASCII characters from CSV
Sed
Awk
Remove all text before colon
R
Unix
Replace
Sed
Awk
Using sed to split a string with a delimiter
Linux
Bash
Sed
String Split
How to UNCOMMENT a line that contains a specific string using Sed?
Bash
Awk
Sed
Replace whitespace with a comma in a text file in Linux
Linux
Shell
Csv
Sed
Awk
How do I run the sed command with input and output as the same file?
Sed
Replace all double quotes with single quotes
Sed
Sed gives: sed: can't read : No such file or directory
Bash
Sed
Quoting
Gnu Sed
How to read output of sed into a variable
Shell
Variables
Sed
Create a dedicated folder for every zip files in a directory and extract zip files
Linux
Shell
Sed
Awk
Unzip
Grep output with multiple Colors?
Bash
Colors
Sed
Awk
Grep
Remove all lines before a match with sed
Sed
sed throws 'bad flag in substitute command'
Macos
Command Line
Sed
Escaping forward slashes in sed command
Bash
Shell
Sed
How to use awk to print lines where a field matches a specific string?
Sed
Awk
What does sed -i option do?
Unix
Sed
Command Line
Option
find matching text and replace next line
Linux
Sed
SED without backup file
Macos
Bash
Sed
Osx Mavericks
sed command in dry run
Sed
Dry
Can not extract the capture group with either sed or grep
Regex
Linux
Sed
Grep
How to globally replace strings in lines NOT starting with a certain pattern
Sed
Use sed to replace all backslashes with forward slashes
Bash
Shell
Sed
How to add a line in sed if not match is found
Bash
Sed
Insert lines in a file starting from a specific line
Bash
Sed
Uppercasing First Letter of Words Using SED
Linux
Bash
Unix
Awk
Sed
How to remove every other line with sed?
Sed
Combining two sed commands
Sed
Splitting a file in linux based on content
Linux
File
Bash
Sed
Awk
sed, replace first line
Sed
how do you specify non-capturing groups in sed?
Linux
Command Line
Sed
delete a column with awk or sed
Sed
Awk
How do I use sed to change my configuration files, with flexible keys and values?
Linux
Bash
Sed
sed: Can my pattern contain an "is not" character? How do I say "is not X"?
Regex
Sed
sed - how to do regex groups using sed
Regex
Linux
Sed
Get Day Of Week in bash script
Bash
Sed
Why does sed require 3 backslashes for a regular backslash?
Regex
Sed
How do I add a line of text to the middle of a file using bash?
Linux
Bash
Sed
Awk
Grep
How to use sed to remove all double quotes within a file
Sed
How to find/replace and increment a matched number with sed/awk?
Bash
Sed
Awk