How Do You Rename Files in Linux Using the Command Line in the Terminal?

Published: 21 August 2021
on channel: Virtual Assistant for Linux
28
1

Let VAL show you how to use the command line in the Linux terminal to rename files.

GROW YOUR CAREER WITH LINUX ️
(Learn and get certified by the experts at the Linux Foundation with this affiliate link)

To rename a single file you can use the mv command. First type mv, then a space, the name of the file, a space, and the new name you wish the file to have. Then press Enter.

You can use ls to check the file has been renamed.

To rename multiple files, first install rename by entering sudo apt install rename.

Now if you want to change a load of jpg files to jpeg. Then type


rename 's/.jpeg/.jpg/' *.jpeg

Support the Channel

VAL utilises the following open source software.
GIMP for thumbnail.
Openshot for video editing.
Mimic for speech.
Kazam for screen recording.
Terminology for terminal emulator.
Featherpad for text editor.
Midnight Commander for managing files.
MX Linux operating system.


Watch video How Do You Rename Files in Linux Using the Command Line in the Terminal? online without registration, duration 01 minute 37 second in high hd quality. This video was added by user Virtual Assistant for Linux 21 August 2021, don't forget to share it with your friends and acquaintances, it has been viewed on our site 28 once and liked it 1 people.