@briananders/two-way-merge

1.0.5 • Public • Published

two-way-merge

This merge tool simply merges two directories into each other. When there is a conflict, the merge takes the file with the later modified date.

Any file that ends with .delete will flag the file as requiring deletion. For instance dirA/path/to/file.delete will delete dirA/path/to/file, dirB/path/to/file, dirA/path/to/file.delete, and dirB/path/to/file.delete

Installation

npm i -g @briananders/two-way-merge

Usage

twowaymerge merge path/to/directory path/to/another/directory

In a crontab chron job, you have to link absolutely as your PATH is empty.

DO NOT DO THIS: twowaymerge merge "~/Google Drive/configs" "~/configs"

Do this: /Users/briananders/.nvm/versions/node/v17.5.0/bin/node /opt/homebrew/lib/node_modules/@briananders/two-way-merge/index.js merge "/Users/briananders/Google Drive/configs" "/Users/briananders/configs"

Dev Setup

  1. Clone the repo
  2. Install dependencies npm i
  3. Globally install the module npm i -g

Dependents (0)

Package Sidebar

Install

npm i @briananders/two-way-merge

Weekly Downloads

1

Version

1.0.5

License

ISC

Unpacked Size

6.37 kB

Total Files

4

Last publish

Collaborators

  • briananders