This happens to me when I'm importing photographs, I end up with files called .JPG or .jpeg and I prefer .jpg.
for file in *.JPG do
This happens to me when I'm importing photographs, I end up with files called .JPG or .jpeg and I prefer .jpg.
for file in *.JPG do
Say you have some files named a100 to a200 that you want to rename to b200 to b100 (it really does happen).
y=200 for x in `seq 100 200` do mv a$x b$((y--)) done
seq is a fairly useful tool, it can also take a reversed list.
for x in `seq 200 -1 100` do printf "$x " done
Currently working as a Puppet Engineer at Wells Fargo. Red Hat Certified Architect with 10 years of Red Hat experience. Puppet and python aficionado who enjoys automating complex tasks. Available for remote contract work.
Copyright 2019 - All Rights Reserved