Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add ‘c’ for capitalized. #29

Merged
merged 1 commit into from
Nov 29, 2024
Merged

Add ‘c’ for capitalized. #29

merged 1 commit into from
Nov 29, 2024

Conversation

balirr
Copy link
Contributor

@balirr balirr commented Nov 25, 2024

Just as 'u' for uppercased, and 'l' for lowercased, 'c' is for capitalized.
It make the first letter of the word or the sentence in uppercased, here are some examples:

1, We have some files like: Scan-23.jpg, SCAN-24.jpg, scaN-25.jpg, when we run
mmv '*' '#c1'
the name of files will be: Scan-23.jpg, Scan-24.jpg, Scan-25.jpg

2, We have files like: FILE NAME IN UPPERCASE.txt, file name in lowercase.txt, we can run
mmv '*\ *\ *\ *.*' '#c1\ #c2\ #c3\ #c4.#5'
the name of files will be: File Name In Uppercase.txt, File Name In Lowercase.txt

@rrthomas
Copy link
Owner

rrthomas commented Nov 25, 2024

Thanks very much, this is an excellent PR description. Please remove the last commit, I prefer "capitalized", which corresponds to "uppercased" and "lowercased", to "capitalization". But I do appreciate that you thought carefully about the choice of words.

@balirr balirr changed the title Add ‘c’ for capitalization. Add ‘c’ for capitalized. Nov 25, 2024
@balirr
Copy link
Contributor Author

balirr commented Nov 25, 2024

Sorry, I haven't had much experience with Git, and my English isn't very good. Please understand. And I've just updated the code following your advice. Thank you.

@rrthomas
Copy link
Owner

No worries, I will take it from here, and your English is excellent!

Just as 'u' for uppercased, and 'l' for lowercased, 'c' is for capitalized.

It capitalizes each word; here are some examples:

1. We have some files like: Scan-23.jpg, SCAN-24.jpg, scaN-25.jpg, when we
run:

mmv '*' '#c1'

the name of files will be: Scan-23.jpg, Scan-24.jpg, Scan-25.jpg

2. We have files like: FILE NAME IN UPPERCASE.txt” and “file name in
lowercase.txt”, we can run:

mmv '*\ *\ *\ *.*' '#c1\ #c2\ #c3\ #c4.rrthomas#5'

the name of files will be: “File Name In Uppercase.txt”, “File Name In
Lowercase.txt”.
@rrthomas rrthomas merged commit 37a3147 into rrthomas:master Nov 29, 2024
2 checks passed
@rrthomas
Copy link
Owner

Many thanks for this PR; I'll make a new release soon!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants