New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

file-names-renamer

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

file-names-renamer

Renames the files in a directory

  • 1.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

file-names-renamer

Renames the files

Usage

To remove last digits with hyphen(-) in file names

- Files
  - DSC_3634-1.jpg
  - DSC_3635-2.jpg
  - DSC_3636-3.jpg
  - DSC_3637-4.jpg
  - DSC_3638-5.jpg
  - DSC_3639-6.jpg
  - DSC_3640-7.jpg
file-names-renamer -d ./testing -s \(\\d.\) -r file\-\$1 -l ./rename.log -i \*.*

The above command will generate following renaming effect on files

- Files
  - DSC_3634.jpg
  - DSC_3635.jpg
  - DSC_3636.jpg
  - DSC_3637.jpg
  - DSC_3638.jpg
  - DSC_3639.jpg
  - DSC_3640.jpg

Parameters

  1. -d, --dir <dir>: Directory to work on
  2. -i, --input-pattern <files>: Directory to work on
  3. -s, --search <search>: Search for the pattern in file name
  4. -r, --replace <replace>: replace with
  5. -l, --log <log>: replace with
  6. -dr, --dry-run: replace with

FAQs

Package last updated on 28 Jun 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc