'rename multiple directories using rename

I have a directory with multiple subdirectories (700 or so) named as such:

ls
quantsSample1
quantsSample2
quantsSample3

I want to bulk rename the subdirectories to remove "quants" from the beginning so it says Sample1, Sample2 etc.

I'm using rename, but it doesn't seem to work:

rename 's/quants//' *

Nothing changes using the above...

Any advice gratefully received. Thanks!



Solution 1:[1]

You can try rename 's/quants*//' *

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Viettel Solutions