Skip to content

Commit d17b238

Browse files
committed
Added publish materials
1 parent 81338b4 commit d17b238

File tree

4 files changed

+60
-7
lines changed

4 files changed

+60
-7
lines changed

.npmignore

-1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
11
# Test directories
22
test
3-
build/test

LICENSE

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
Copyright 2017 Axosoft, LLC
2+
3+
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4+
5+
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
6+
7+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

README.md

+49-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,49 @@
1-
nodegit-lfs
1+
# NodeGit LFS
2+
3+
Nodegit LFS is an extension library used to augment [NodeGit](http://www.nodegit.org/) with the capability to use [git lfs](https://git-lfs.github.com/) via the command line.
4+
5+
To use this package, you must have [git](https://git-scm.com/) and [git lfs](https://git-lfs.github.com/) installed.
6+
7+
This project is new, and is highly volatile. It should be noted that any subsequesnt releases may have breaking changes for the foreseeable future.
8+
9+
## How to get started
10+
11+
`NodeGit` is a peer dependency of the `NodeGit LFS` package, so you should make sure to install `NodeGit` before `NodeGit LFS`.
12+
13+
To install `NodeGit` run:
14+
15+
`yarn add nodegit`
16+
17+
To install `NodeGit LFS` run:
18+
19+
`yarn add nodegit-lfs`
20+
21+
Once installed, you only need to bootstrap `NodeGit LFS` once:
22+
23+
```javascript
24+
const nodegit = require('nodegit');
25+
const addLfs = require('nodegit-lfs');
26+
27+
// Call the function returned from nodegit-lfs with nodegit as a parameter
28+
// and you are good to go!
29+
addLfs(nodegit);
30+
31+
// After nodegit has been augmented you can use LFS via the LFS object
32+
nodegit.LFS.register()
33+
.then(() => {
34+
console.log('The LFS filter has been registered!');
35+
});
36+
```
37+
38+
## Building from source
39+
40+
Clone the repo:
41+
42+
`git clone https://github.com/axosoft/nodegit-lfs`
43+
44+
Once cloned:
45+
46+
```
47+
cd nodegit-lfs
48+
yarn
49+
```

package.json

+4-5
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
"eslint": "\"node_modules/.bin/eslint\" src test/tests",
1010
"eslint-quick-fix": "\"node_modules/.bin/eslint\" src test/tests --fix",
1111
"pretest": "yarn eslint",
12-
"postinstall": "yarn compile",
12+
"prepublish": "yarn eslint && yarn compile",
1313
"src-watch": "\"node_modules/.bin/babel\" src -d build/src -w",
1414
"test": "nyc mocha --compilers js:babel-core/register --expose-gc test/runner \"test/**/*.spec.js\"",
1515
"test-debug": "mocha --debug-brk --compilers js:babel-core/register --expose-gc test/runner \"test/**/*.spec.js\"",
@@ -24,10 +24,9 @@
2424
"lfs",
2525
"nodegit"
2626
],
27-
"directories": {
28-
"build": "./build",
29-
"test": "./test/tests"
30-
},
27+
"files": [
28+
"build/src"
29+
],
3130
"bugs": {
3231
"url": "https://github.com/Axosoft/nodegit-lfs/issues"
3332
},

0 commit comments

Comments
 (0)