hosso / git-ss

Save a snapshot of a directory to git

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

git-ss

Save a snapshot of a directory to git.

Installation

npm install git-ss
# or
yarn add git-ss

Usage

CommonJS

const { pushToGit } = require('git-ss');

async function takeSnapshot() {
  await pushToGit('./mydata', 'https://github.com/hosso/mybackup.git');
}

takeSnapshot();

TypeScript

import { pushToGit } from 'git-ss';

async function takeSnapshot() {
  await pushToGit('./mydata', 'https://github.com/hosso/mybackup.git');
}

takeSnapshot();

License

MIT

About

Save a snapshot of a directory to git

License:MIT License


Languages

Language:TypeScript 98.3%Language:JavaScript 1.7%