All Questions
11 questions
2
votes
2
answers
61
views
Renaming file name with shell script
I have lots of file name like below;
KO.ADVT..HHE.D.2017.163.121959.SAC
KO.ADVT..HHN.D.2017.163.121957.SAC
KO.ADVT..HHZ.D.2017.163.121959.SAC
KO.ARMT..HHE.D.2017.163.121957.SAC
KO.ARMT..HHN.D.2017.163....
0
votes
0
answers
127
views
Script acts differently in different directories
I have a simple script that I pulled out of a larger script dedicated to renaming files with odd characters in the name. I have run this successfully on the same machine within different directories, ...
0
votes
2
answers
386
views
Renaming files by removing delimited substring
I have a lot of folders and subfolders with files with name 1. Introduction--- [ FreeCourseWeb.com ] ---.mp4 I want to rename all files recursively (folders and subfolders) to just 1. Introduction.mp4 ...
2
votes
2
answers
2k
views
Copying/Moving folders where destination folder already exists
I am writing a bash script to copy/move a folder called "folder" to a directory that already contains "folder" and I would like the contents to be merged.
I am attempting to use a solution from this ...
9
votes
3
answers
5k
views
Change only the extension of a file [duplicate]
I am working on a simple shell script to change a file one.PDF to one.pdf. I have this file stored in a folder called Task1.
My script is in the same directory as Task1. Called Shell1.sh When I run ...
0
votes
1
answer
747
views
Sorting files by filename
I'm trying to sort my files by pattern into filename by creating Linux Script (Bash).
My files are mostly .JPG, some .AV and .MP4. I can't use meta tags, because this files have broken tags (restored ...
0
votes
1
answer
1k
views
can mmv rename files by incrementing an index?
Can mmv, a mass move utility, nicely rename files from:
foo.txt
bar.txt
baz.txt
to:
1.txt
2.txt
3.txt
The man page is intriguing, but I don't quite follow the directions:
Rename all *.jpeg ...
3
votes
2
answers
216
views
How to keep exactly one file in a directory?
I have recovered files and currently they have this structure:
root/MD5_of_file1/file1
root/MD5_of_file2/file2
...
root/MD5_of_filen/filen
Obviously, duplicates are now in the same folder. The ...
1
vote
3
answers
1k
views
Script to move one filetype and create a subfolder, if it exists?
I'm trying to find a script that would basically look recusively at a directory, and if the script finds file that are .flac files, it will create a subfolder called FLAC in that same folder, and move ...
2
votes
1
answer
126
views
Copy files that partially matches another files in another location
I have a list of jpeg files in a directory like this (below is just a sample, like the structure is the same but this there are many fo0# sub-folders, not only fo01 and fo01, where each of these ...
11
votes
2
answers
11k
views
Create sub-directories and organize files by date
I have some directories of files copied from my security camera that I would like to organize into sub-directories by file date. So for example;
-rwxrwxrwx 0 root root 4935241 Jul 19 2012 DSCN1406....