0

I have some markdown files that I want to move to a different directory called "newDirectory2" within "newDirectory1".

These files contain the string "abc" or "ABC" or "Abc" somewhere in their titles

I tried the following command:

rename 's/newDirectory1\/newDirectory2\/$1/s' 's/(^.*[abc|ABC|Abc].*.md)/s' 

But it doesn't work :/, what I'm doing it wrong? please help

1
  • 1
    You need to study Rename's syntax more carefully, for there are several mistakes in your attempt. Composing a minimal, reproducible example (with some sample files before/after the operation) is very helpful too. Commented Jan 26, 2021 at 21:59

1 Answer 1

1

I think you're overcomplicating the issue. A straightforward mv will achieve what you're asking,

mv *[Aa][Bb][Cc]* newDirectory1/newDirectory2 

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.