Jump to content

Bat Script Explanation


Recommended Posts


The script takes a file/folder as a parameter %1

e.g. C:\APath\ADir\AFilename.ext

It takes this parameter and sets it as a variable set test=%1

set test=C:\APath\ADir\AFilename.ext

Then it performs a rename operation using the last 13 characters of the %test% variable. ren %1 APP_PROD_ABC_%test:~13%

ren C:\APath\ADir\AFilename.ext APP_PROD_ABC_AFilename.ext

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...