Origin Project: https://github.com/larsalbrecht/jsrenamer
Elec Renamer is a simple tool to rename files.
// TODO
Example Input Files:
/directory/to/example.file - 001.txt
/directory/to/example.file - 02.txt
/directory/to/example.file - 004.txt
/directory/to/example.file - 41.txt
/directory/to/example.file.jpg
You can filter the files by file extension.
Input: txt
Output:
/directory/to/example.file - 001.txt
/directory/to/example.file - 02.txt
/directory/to/example.file - 004.txt
/directory/to/example.file - 41.txt
Input: jpg
Output:
/directory/to/example.file.jpg
Tags can be used inside the upper input. The Tags can be combined.
The Counter-Tag is for generating a number. So you can enumerate a list of files.
Input: [c]
Output:
0
1
2
3
4
Input: [c, 10]
Output:
10
11
12
13
14
Input: [c, 10, 5]
Output:
10
15
20
25
30
Input: [c, 10, 5, 4]
Output:
0010
0015
0020
0025
0030
The Date-Tag is for generating a date. So you can add a date to a list of files. The allowed signs for the format can be found here: https://date-fns.org/v1.30.1/docs/format
Input: [d]
Output:
2019-06-15
2019-06-15
2019-06-15
2019-06-15
2019-06-15
Input: [d, D.MM.YYYY]
Output:
15.06.2019
15.06.2019
15.06.2019
15.06.2019
15.06.2019
The FileExtension-Tag is for getting the current file extension.
Input: [e]
Output:
.txt
.txt
.txt
.txt
.jpg
Input: [e, false]
Output:
txt
txt
txt
txt
jpg
The Folder-Tag is to get a part of the directory to a file.
Input: [f]
Output:
to
to
to
to
to
Input: [f, 1]
Output:
directory
directory
directory
directory
directory
Input: [f, 1, 1]
Output:
irectory
irectory
irectory
irectory
irectory
Input: [f, 1, 1, 1]
Output:
i
i
i
i
i
The Filename-Tag is to get a part of the name of a file.
Input: [n]
Output:
example.file - 001.txt
example.file - 02.txt
example.file - 004.txt
example.file - 41.txt
example.file.jpg
Input: [n, 8]
Output:
file - 001.txt
file - 02.txt
file - 004.txt
file - 41.txt
file.jpg
Input: [n, 8, 2]
Output:
fi
fi
fi
fi
fi
The Text-Size-Tag is a special Tag. You can ignore the end-tag if you want to change the case of all signs.
u
= uppercasel
= lowercasewu
= word uppercasewl
= word lowercase
Input: [ts, u]abcdef[/ts]
Output:
ABCDEF
ABCDEF
ABCDEF
ABCDEF
ABCDEF
Input: [ts, l]ABCDEF[/ts]
Output:
abcdef
abcdef
abcdef
abcdef
abcdef
Input: [ts, wu]this is an example[/ts]
Output:
This Is An Example
This Is An Example
This Is An Example
This Is An Example
This Is An Example
Input: [ts, wl]THIS IS AN EXAMPLE[/ts]
Output:
tHIS iS aN eXAMPLE
tHIS iS aN eXAMPLE
tHIS iS aN eXAMPLE
tHIS iS aN eXAMPLE
tHIS iS aN eXAMPLE
The Text-Tag is a simple Tag to add text.
Input: [t, "EXAMPLE!!"]
Output:
EXAMPLE!!
EXAMPLE!!
EXAMPLE!!
EXAMPLE!!
EXAMPLE!!
You can add a list with texts to add the text to the filename. Each line is one file. To use this, you can use the Text-Tag:
Inputlist:`
1st Entry
2nd Entry
3rd Entry
4th Entry
Input: [t, $list$]
1st Entry
2nd Entry
3rd Entry
4th Entry
example.file.jpg
With the Input-Replacer you can replace specific text. You can add multiple replacers to replace also multiple different texts.
- Before: The text inside must before the search word.
- Not (Before): With this option, the text from "Before" must not be present.
- Search: This is the search word to search for.
- After: The text inside must after the search word.
- Not (After): With this option, the text from "After" must not be present.
- Replace With: This is the value that will be replaced with the found in "Search".
- Replace all: By default, only the first find is replaced. With this option all finds will be replaced.
Input: This is an example sentence to demonstrate the input replacer.
- Search:
an example
- Replace With:
a
Output: This is a sentence to demonstrate the input replacer.
- Search:
- Replace With:
-
- Replace All:
checked
Output: This-is-an-example-sentence-to-demonstrate-the-input-replacer.
- Before:
e
- Search:
- Replace With:
-
- Replace All:
checked
Output: This is an example-sentence-to demonstrate-the-input replacer.
- Before:
e
- Not (Before):
checked
- Search:
- Replace With:
-
- Replace All:
checked
Output: This-is-an-example sentence to-demonstrate the input-replacer.
- Search:
- After:
t
- Replace With:
-
- Replace All:
checked
Output: This is an example sentence-to demonstrate-the input replacer.
- Search:
- After:
t
- Not (After):
checked
- Replace With:
-
- Replace All:
checked
Output: This-is-an-example-sentence to-demonstrate the-input-replacer.