@hexemeister/filediff
v0.0.5
Published
a tool to export different rows in text files
Downloads
4
Maintainers
Readme
📝 Table of Contents
🧐 About
At first, this project is just a javascript study.
But it has come from a true necessity: to compare 2 files and export what differs between them.
🏁 Getting Started
These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.
Prerequisites
Node.js only. If you don't have it installed, check at its webpage to download it first.
Installing
Having Node.js installed, just install the package globally.
npm i -g @hexemeister/filediff
And wait a bit. When npm stops grumbling you're ready.
filediff -v
This will output the tool version.
Note that for one time run you can just use npx.
npx @hexemeister/filediff file1.txt file2.txt
🎈 Usage
Basic usage is:
filediff file1 file2
This will compare file1 with file2 and export the difference between these two to filediff.txt. Mind that the tool has a default command called export. Since it's the default command, you can omit as above example.
filediff export file1 file2
This will do the exactly the same as the first example. You can skip export command with no problem.
Note that order matters here. Actually, the command checks what file1 has and file2 doesn't. You can swap both filenames just adding a -i option instead of rewriting the command switching both filenames.
filediff -i file1 file2
The command above is the same as if you had written filediff file2 file1. Another thing to notice is that the default result filename is filediff.txt. You can specify a custom result filename by adding -t .
filediff file1 file2 -t result.txt
This will have you a result.txt at the end of the comparison.
For more information, check its help:
filediff -h
⛏️ Built Using
- NodeJs - Server Environment
- CommanderJS - Cli Framework
- Figlet - Figfont
✍️ Authors
- @hexemeister - Idea & Initial work
See also the list of contributors who participated in this project.
🎉 Acknowledgements
- Hat tip to anyone whose code was used
- Inspiration
- References