Txt

Byte sized tech know-how.

  • Home
  • About

Tag Archives: empty

07 Feb

Remove Empty Lines

Remove empty lines from a file using sed


sed '/^$/d' file.txt

Original Article

admin Posted in Command Line, Linux blank, command, empty, line, Linux, remove, sed, text Leave a comment
13 Sep

Remove empty directories

Remove all empty directories within the current directory


find . -type d -empty -exec rmdir {} \;
perl -MFile::Find -e"finddepth(sub{rmdir},'.')"

Delete Empty Directories
http://www.jonasjohn.de/lab/red.htm
[tags]empty,folder,delete,remove,perl,command,linux[/tags]

admin Posted in Command Line, Linux, Perl command, delete, empty, folder, Linux, Perl, remove Leave a comment

Post navigation

Categories

  • Code
  • Command Line
  • Configuration
  • CSS
  • HTML
  • internet
  • JavaScript
  • Linux
  • Mobile
  • Perl
  • PHP
  • Python
  • Ruby
  • Uncategorized

Meta

  • Log in
  • Entries feed
  • Comments feed
  • WordPress.org
Fruitful theme by fruitfulcode Powered by: WordPress
↑