|
Answer» Hello
i have much files in directory and... i wanna change/delete some characters on FILE names....
1) i wanna delete/change double or more space (to one space) on file names ("Ali .avi" to "Ali .avi" ; "Ali Osman.avi" to " Ali Osman.avi") mean (" " to " ") have 2 space on file names.. i wanna change to one space on ALL filenames
2) i wanna delete/change special chars on file names = ()!'#$,@ ............ ( i wanna add more other days) original file name = Ali's kitchen.avi when changed with space = "Ali s kitchen.avi" or when deleted = "Alis kitchen.avi"
i wanna change "'" to " " or i wanna delete this chars on file name
3) i wanna change special chars on files name = 'è' -> 'e' ; '’' -> ' ' ; '•' -> '-' ; '…' -> '...' ; '—' -> '-' ; 'ä' -> 'a' ; 'ß' -> 'B' ; '“' -> '"' ; "ö" to "o" (óñíéáú¿¡”“’€ ) and more..... sample file name... "Göber.avi" wanna change "Gober.avi" others = "Últimos.wmv" to "Ultimos.wmv" others = "espanól" to "espanol"
4) i wanna change special file names = "Ali 1.jpg" -> "Ali cvr.jpg" ; "Hasan Osman 1.jpg" Hasan Osman cvr.jpg" mean last char " 1.jpg" to " cvr.jpg" if possible NO mistake on all files. i can use it ren "* 1.jpg" "* cvr.jpg"
5) i wanna change space to underline... mean "ali 1.jpg" to "ali_1.jpg" ; "hasan osman ayse 1.jpg" to "hasan_osman_ayse_1.jpg"
6) i wanna change file extensions.. ( "*.JPG" to "*.jpg" ; "*.JPEG to *.jpg" ; "*.jpeg" to "*.jpg" ; "*.asf" to "*.wmv" ; "*.flv" to "*.mp4" ; "*.m4v" to "*.mp4" .... and mores) i can do with Code: [Select]for videos... ren *.flv *.mp4 ren *.m4v *.mp4 ren *.f4v *.mp4 all type converting to mp4 extentions.. but using 3 sommand lines..
for images... ren *.JPG *.jpg ren *.JPEG *.jpg ren *.jpeg *.jpg how can change all images variants to jpg format with ONE command ? and for videos
7) how i can part files with rar.exe on command line (32 or 64 bit microsoft SYSTEM ? i will insert some variants wanted files size = 200MB min file size = 100MB part type = storage or compress password = ... (if wanna insert) info = .... when opended rar file/s will show right side addable files = ... ( i have some info or readme-files.txt or with logo.jpg or other extra files) can possible ?
thank you very much For a lot of those changes you can use the Multi-rename tool in the shareware-fully functional "Total Commander" http://www.ghisler.com/
You open the main folder, hit control B to list all files in the tree, hit * on the numpad to mark them all (in this view folder names aren't marked) , and then control M to enter the Multi Rename tool and you can perform renames etc on every file in the tree in one go.
After each rename, repeat the steps to mark all files and do another change.
You can rename/replace/delete text or characters in all sorts of ways including regular expressions - operations are performed on all the marked files, and they remain in the same folder they were in.
A number of your changes would be simply done within 10 or so minutes.
For EG: Open the main folder and hit control B to gather all the files in the tree into one list. hit + on the numpad and type in *.jpg to mark all .jpg files - hit Enter hit + on the numpad and type in *.jpeg to mark all .jpeg files - hit Enter
You have all .jpg and all .jpeg files marked, so hit control M to enter the Multi rename tool and then change the extension to jpg in lower case.
Be very careful when you mark files - you don't want files to be marked that you don't want changed. The marked ones are in a different colour.
Test it on a single folder of copies of your files until you are familiar with the process. The Insert key marks single files.
Once you change the simpler things then come back with a list of the things you still need to be done and we can help with a script.
Quote FWIW Total Commander is a very capable file manager and has zillions of options you can change, and configure, starting with the colour/layout of the dual pane windows and colour of different filetypes. It remains fully functional shareware and never times out
A paid license gives you good karma I guess, and removes the startup prompt. The license is good forever, for all updates TC is my favourite Windows program since the 16 bit version in Windows 9x. Hello
i know execute programs.. and still using.. have much better from totalcommander
but... if i can create batch files... i can add to mouse right click.. and dont need programs... because.. i am very offen doing same works..
i wanna use with bacth command.. i will call bat files in directory and will do all works with mouse clicks. very fast and very easy.. no need programs... batch files.. fast and easy
but.. i dont know create .. cant write scripts
sorry...Ok. It's just that you're asking for a LARGER project than is usual and whoever helps you will need a full list of the foreign characters that you need to change, because batch can be difficult with foreign characters.
You will also have to provide them with a complete list of characters you want to change, and delete, and all filespecs that you want renamed.
The rar section is also not very clear to me.Please do not ask for private help via PM. This forum is for learning and solving problems for everybody.
EDIT: It occurs to me that you aren't converting text files, but are changing filenames.
Do a DIR /B /A-D >"input file.txt" and test that file anyway, to see if it changes the characters properly. If it does then we can take it another step.
This code uses GnuSED which is a free download. It replaces the characters like this "y/abc/123/" and it is called a transliteration command: where a will be replaced with 1 where b will be replaced with 2 where c will be replaced with 3
and so on.
The characters in the left side below of the y/// transliteration command are what I see in your PM. In various cases what I see may not be what you intended.
Anyway, test this after downloading GnuSED using this syntax: changechar "input file.txt" "output file.txt"
You will see \x22 in a few places and that is to replace the corresponding letter with a quote and that represents hex 22 in the ASCII code.
Code: [Select]:: changechar.bat @echo off chcp 1252
sed -e "y/è’•—äß“”éü×ö·‘–¨ïàá«»êéôáñ—áíóñúÁé—/e---aB\x22\x22euxo-\x22-\x22iaa<>eeoan-aionuAe-/" -e "s/¿//g" -e "s/?//g" -e "s/#//g" -e "s/\$//g" -e "s/%%//g" -e "s/´//g" -e "s/&/and/g" -e "s/…/.../g" "%~1" > "%~2"
pause
The request follows:
QuoteQuote from: TosunPASA on FEBRUARY 20, 2014, 09:07:29 AMHello
thanks for help
i dont wanna use any program for my works but using... sometimes i dont remember problems. and some characs noted by me i am using with filere-namers.. because.. some changes dont understand... example.. flashrenamer dont understand double spaces or.. dont understand first " 1.jpg" to " cvr.jpg"... i am using fast file renamer program for it. but.. i am using flashrenamer program for one space " " to "_" because.. that program can repeated to finish.. if i will use fast filerenamer. cant repeate... i must click again by again for update result zero..
Code: [Select]'è','e' '’',' ' '•','-' '…','...' '—','-' '—','-' 'ä','a' 'ß','B' '“','"' '”','"' 'é','e' 'ü','u' '×','x' 'ö','o' '·','-' '‘','"' '–','-' '¨','"' 'ï','i' 'à','a' 'á','a' '«','<' '»','>' 'ê','e' 'é','e' 'ô','o' '´',' ' 'á','a' 'ñ','n' '—','-' 'á','a' 'í','i' 'ó','o' 'ñ','n' 'ú','u' 'Á','A' 'é','e' '¿','' '—','-' '?','' '#','' '$','' '%','' '&','and'this list todays using my updates.. some times.. coming new updates from other languages.. i am changing to standart alphabets.
could you help for update/delete for batch files ?
because... i will create steps for everyting.. main batch file will call other batch files.. example.. (main.bat) 1.step.. i will delete double spaces 2.step.. i will change non-regular chars 3.step.. i will change change file extantions 4.step.. i will change file names and will merge images for main files. and others... others....
thank you very much
|