Created
July 18, 2019 10:43
-
-
Save Matrix7867/4cd4f086dbf917107e06e2be49acf51f to your computer and use it in GitHub Desktop.
rename any files with three digit 000 increment
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| count=001 | |
| newname=segmentmembership | |
| for i in *.json.gz; | |
| do | |
| c=`printf '%0.3d\n' $count` | |
| mv $i $newname.$c.json.gz | |
| count=$((count+001)) | |
| done |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment