Menu

Close
  • Home
Subscribe
Menu

grep

A 1-post collection

Page 1 of 1

Bash: Move an Entire Directory of Files

I recently wanted to nest all the files in a folder one level deeper. Which meant I needed to move all the files except for the nested folder I created. This will move all files, excluding the directory new-folder: ls|grep -v new-folder|xargs -I % mv »

Mark J. Miller on linux, bash, xargs, grep 08 January 2016
Page 1 of 1
developMENTALmadness © 2017
Casper theme powered by Ghost