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

file-patch

Package Overview
Dependencies
Maintainers
1
Versions
5
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

file-patch

command line diff / patch tool for https://github.com/google/diff-match-patch

  • 0.3.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
133
decreased by-50.19%
Maintainers
1
Weekly downloads
 
Created
Source

file-patch

Command line diff / patch tool for https://github.com/google/diff-match-patch

npm version

file-patch can compare and modify any text base files in any operating system.

If you have modified some part of your dependent modules or libraries (modified certain block in apache config, change color for blog theme...) file-patch can reduce your effort to maintain and upgrade these files.

Install

You can install it via npm

npm install file-patch

Usage

After install the package provides file-diff and file-patch commands. They can be used to compare and modify any text base files.

Examples

You can find some examples in the source repo. Each example contain 3 files:

  • the origin file
  • the modified file (with -mod mid-fix)
  • the diff file (with .diff subfix)

You can run npm run examples-diff command to genereate .diff file via file-diff. Or run npm run examples-patch command to make the origin file exactly the same as the modified file.

file-diff

file-diff can compare 2 files and generate the diff-style file.

$ file-diff file1 file2

will generate file1.diff near file1

file-patch

file-patch can apply the diff file to the target file.

$ file-patch file1.diff file

will apply patch file (file1.diff) to file1.

Keywords

FAQs

Package last updated on 10 Feb 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