In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-05 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/03 Report--
This article will explain in detail what you need to pay attention to when using wildcards for ren commands. The editor thinks it is very practical, so I share it with you for reference. I hope you can get something after reading this article.
1 、
Ren full file name * specifies any character or consecutive string in the full file name. Extension name
Change the file name to: wildcard from the beginning of the original file name to the specified character (string). Extension name
Such as:
Ren 10.pdf * 0.c gets 10.c
Ren 10.pdf * p.c get 10.p.c
Ren 10.pdf * d.c gets 10.pd.c
2 、
Ren full file name * specifies a non-contiguous string of the full file name. Extension name
Change the file name to: from the beginning of the original file name to the specified string initiator + the rest of the string content. Extension name
Such as:
Ren 10.pdf * 1p.c gets 1p.c
Ren 10.pdf * 0dp.c gets 10dp.c
3 、
Ren full file name * specifies except any character (string) in the complete file name. Extension name
Change the file name to: wildcard full file name + specified character (string). Extension name
Such as
Ren 10.pdf * mm.c gets 10.pdfmm.c
Originally posted by bjsh at 2007-4-13 10:10 PM:
Create a new 10.pdf on disk c
Execute the following two commands
Look at what 10.pdf was renamed at last.
Ren 10.pdf * 2.c
The result is: 10.pdf2.c
Ren 10.pdf * 1.c
The result is 1.c
Ren 10.pdf * 2.c
* what is the first word after it?
two
Is there a word in 10.pdf?
No. So, it's in the back.
10.pdf
2.c
10.pdf2.c
Ren 10.pdf * 1.c
* what is the first word after it?
one
Is there a word in 10.pdf?
Yes. Look for the first one you find in the back.
Delete after 10.pdf 1
1.C 1 and then connect it
1.c
Ren 10010.pdf * 1.c
* what is the first word after it?
one
Is there a word in 10010.pdf?
Yes. Look for the first one you find in the back.
Delete after 10010.pdf 1
1.C 1 and then connect it
1001.c
Special case ren.
Ren * "*"
FAT32
C:\ TEST > cd. > 123...456...789.mp3
C:\ TEST > dir/b
123...456...789.mp3
C:\ TEST > ren *.
C:\ TEST > dir/b
123...456...789
C:\ TEST > ren *.
C:\ TEST > dir/b
one hundred and twenty three
-
C:\ TEST > cd. > "123456 789.mp3"
C:\ TEST > dir/b
123 456 789.mp3
C:\ TEST > ren * "*"
C:\ TEST > dir/b
one hundred and twenty three
C:\ TEST > for% an in (*) do @ echo "% a"
"123"
NTFS
D:\ TEST > cd. > 123...456...789.mp3
D:\ TEST > dir/b
123...456...789.mp3
D:\ TEST > ren *.
D:\ TEST > dir/b
123...456...789
D:\ TEST > ren *.
D:\ TEST > dir/b
123...456
D:\ TEST > ren *.
D:\ TEST > dir/b
one hundred and twenty three
-
D:\ TEST > cd. > "123456 789.mp3"
D:\ TEST > dir/b
123 456 789.mp3
D:\ TEST > ren * "*"
D:\ TEST > dir/b
123 456
D:\ TEST > for% an in (*) do @ echo "% a"
"123456"
D:\ TEST > ren * "*"
D:\ TEST > dir/b
one hundred and twenty three
D:\ TEST > for% an in (*) do @ echo "% a"
"123"
This is the end of this article on "what do you need to pay attention to when ren commands use wildcards?". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, please share it for more people to see.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.