git-cherrypicker
Advanced tools
Comparing version 0.0.3 to 0.0.4
@@ -19,6 +19,1 @@ export declare const giteaArg = "{{host}}/{{reponame}}/raw/branch/{{branchname}}/{{filename}}"; | ||
} | ||
export declare class GitCloner { | ||
private url; | ||
constructor(host: string, owner: string, repo: string, cred?: [string, string]); | ||
clone(dest: string): void; | ||
} |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
const node_fetch_1 = require("node-fetch"); | ||
const git = require("simple-git/promise"); | ||
const path = require("path"); | ||
const fs_1 = require("fs"); | ||
@@ -57,17 +55,1 @@ exports.giteaArg = "{{host}}/{{reponame}}/raw/branch/{{branchname}}/{{filename}}"; | ||
exports.FrontblockCherryPicker = FrontblockCherryPicker; | ||
class GitCloner { | ||
constructor(host, owner, repo, cred) { | ||
if (cred) { | ||
this.url = 'https://' + cred[0] + ':' + cred[1] + '@' + path.join(host, owner, repo); | ||
} | ||
else { | ||
this.url = 'https://' + path.join(host, owner, repo); | ||
} | ||
} | ||
clone(dest) { | ||
git().clone(this.url, dest) | ||
.then(() => console.log('finished')) | ||
.catch((err) => console.error('failed: ', err)); | ||
} | ||
} | ||
exports.GitCloner = GitCloner; |
{ | ||
"name": "git-cherrypicker", | ||
"version": "0.0.3", | ||
"version": "0.0.4", | ||
"description": "Read files from popular git implementations as string or write them to a file", | ||
@@ -17,6 +17,4 @@ "main": "lib/CherryPicker.js", | ||
"fs": "0.0.1-security", | ||
"node-fetch": "^2.6.0", | ||
"path": "^0.12.7", | ||
"simple-git": "^1.124.0" | ||
"node-fetch": "^2.6.0" | ||
} | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
3
3330
72
- Removedpath@^0.12.7
- Removedsimple-git@^1.124.0
- Removeddebug@4.3.7(transitive)
- Removedinherits@2.0.3(transitive)
- Removedms@2.1.3(transitive)
- Removedpath@0.12.7(transitive)
- Removedprocess@0.11.10(transitive)
- Removedsimple-git@1.132.0(transitive)
- Removedutil@0.10.4(transitive)