U
U
Urukhayy2017-07-31 09:52:26
System administration
Urukhayy, 2017-07-31 09:52:26

Bulk rename files on Centos 7?

Given:

a-catalog/
   a.component.html
   a.component.ts
   a.component.spec.ts
   a.component.css

Should be renamed to:
b-catalog/
   b.component.html
   b.component.ts
   b.component.spec.ts
   b.component.css

How to make it more convenient and easier? And there will be many such renames, this is just one directory.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
J
JaxxDexx, 2017-07-31
@Urukhayy

yum install mmv

mmv 'a.*' 'b.#1'

P
pfg21, 2017-07-31
@pfg21

A full-fledged regexp is in the standard command But if you understand and look for a break, put gprename ??

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question