Skip to content

Instantly share code, notes, and snippets.

@ngc-bg
ngc-bg / sed cheatsheet
Created May 15, 2022 08:23 — forked from freewind/sed cheatsheet
magic of sed -- find and replace "text" in a string or a file
FILE SPACING:
# double space a file
sed G
# double space a file which already has blank lines in it. Output file
# should contain no more than one blank line between lines of text.
sed '/^$/d;G'
@ngc-bg
ngc-bg / ntfs-filenames.txt
Created November 23, 2020 11:48 — forked from doctaphred/ntfs-filenames.txt
Invalid characters for Windows filenames
Information from https://docs.microsoft.com/en-us/windows/win32/fileio/naming-a-file :
Use any character in the current code page for a name, including Unicode
characters and characters in the extended character set (128–255), except
for the following:
- The following reserved characters:
< (less than)
> (greater than)