@blockstack/clarity-native-bin
Advanced tools
Comparing version 0.3.0 to 0.3.3
@@ -6,2 +6,3 @@ import { ILogger } from "./logger"; | ||
outputFilePath: string; | ||
buildPackage: string; | ||
gitBranch?: string; | ||
@@ -8,0 +9,0 @@ gitTag?: string; |
@@ -59,3 +59,4 @@ "use strict"; | ||
"--root", | ||
tempCompileDir | ||
tempCompileDir, | ||
opts.buildPackage | ||
]; | ||
@@ -62,0 +63,0 @@ if (opts.overwriteExisting) { |
import { ILogger } from "./logger"; | ||
declare const enum SupportedDistPlatform { | ||
WINDOWS = "win", | ||
MACOS = "mac", | ||
WINDOWS = "windows", | ||
MACOS = "macos", | ||
LINUX = "linux", | ||
@@ -6,0 +6,0 @@ LINUX_MUSL = "linux-musl" |
@@ -17,3 +17,3 @@ "use strict"; | ||
const path = __importStar(require("path")); | ||
const tar = __importStar(require("tar")); | ||
const unzip = __importStar(require("unzipper")); | ||
const detectArch_1 = require("./detectArch"); | ||
@@ -23,4 +23,4 @@ const detectLibc_1 = require("./detectLibc"); | ||
const streamUtil_1 = require("./streamUtil"); | ||
const DIST_DOWNLOAD_URL_TEMPLATE = "https://github.com/blockstack/clarity-js-sdk/releases/" + | ||
"download/{tag}/clarity-cli-{platform}-{arch}.tar.gz"; | ||
const DIST_DOWNLOAD_URL_TEMPLATE = "https://github.com/blockstack/stacks-blockchain/releases/" + | ||
"download/{tag}/{platform}-{arch}.zip"; | ||
/** | ||
@@ -48,6 +48,6 @@ * Checks if the currently executing platform and architecture has an distributable available | ||
case "cygwin": | ||
platform = "win" /* WINDOWS */; | ||
platform = "windows" /* WINDOWS */; | ||
break; | ||
case "darwin": | ||
platform = "mac" /* MACOS */; | ||
platform = "macos" /* MACOS */; | ||
break; | ||
@@ -107,4 +107,4 @@ case "linux": | ||
opts.logger.log(`Extracting to temp dir ${tempExtractDir}`); | ||
const tarStream = tar.extract({ cwd: tempExtractDir }); | ||
await streamUtil_1.pipelineAsync(httpResponse.body, tarStream); | ||
const unzipStream = unzip.Extract({ path: tempExtractDir }); | ||
await streamUtil_1.pipelineAsync(httpResponse.body, unzipStream); | ||
const binFileName = fsUtil_1.getExecutableFileName("clarity-cli"); | ||
@@ -115,2 +115,3 @@ const tempBinFilePath = path.join(tempExtractDir, binFileName); | ||
fs.removeSync(tempExtractDir); | ||
fs.chmodSync(opts.outputFilePath, 0o775); | ||
return true; | ||
@@ -117,0 +118,0 @@ } |
@@ -6,3 +6,3 @@ import { ILogger } from "./logger"; | ||
*/ | ||
export declare const CORE_SDK_TAG = "clarity-sdk-v0.1.2"; | ||
export declare const CORE_SDK_TAG = "v23.0.0.12-krypton"; | ||
export declare const BLOCKSTACK_CORE_SOURCE_TAG_ENV_VAR = "BLOCKSTACK_CORE_SOURCE_TAG"; | ||
@@ -9,0 +9,0 @@ export declare const BLOCKSTACK_CORE_SOURCE_BRANCH_ENV_VAR = "BLOCKSTACK_CORE_SOURCE_BRANCH"; |
@@ -20,3 +20,3 @@ "use strict"; | ||
*/ | ||
exports.CORE_SDK_TAG = "clarity-sdk-v0.1.2"; | ||
exports.CORE_SDK_TAG = "v23.0.0.12-krypton"; | ||
exports.BLOCKSTACK_CORE_SOURCE_TAG_ENV_VAR = "BLOCKSTACK_CORE_SOURCE_TAG"; | ||
@@ -111,2 +111,3 @@ exports.BLOCKSTACK_CORE_SOURCE_BRANCH_ENV_VAR = "BLOCKSTACK_CORE_SOURCE_BRANCH"; | ||
outputFilePath: installPath, | ||
buildPackage: "blockstack-core", | ||
gitBranch: versionBranch, | ||
@@ -140,3 +141,3 @@ gitTag: versionTag, | ||
if (opts.fromSource) { | ||
return cargoBuild_1.cargoInstall(Object.assign(Object.assign({}, opts), { gitTag: opts.versionTag })); | ||
return cargoBuild_1.cargoInstall(Object.assign(Object.assign({}, opts), { buildPackage: "blockstack-core", gitTag: opts.versionTag })); | ||
} | ||
@@ -143,0 +144,0 @@ else { |
{ | ||
"name": "@blockstack/clarity-native-bin", | ||
"version": "0.3.0", | ||
"version": "0.3.3", | ||
"description": "Library for providing the native Clarity CLI binary", | ||
@@ -42,3 +42,3 @@ "author": "Blockstack <engineering@blockstack.com> (https://blockstack.com/)", | ||
"semver": "^6.1.1", | ||
"tar": "^4.4.8" | ||
"unzipper": "^0.10.11" | ||
}, | ||
@@ -52,3 +52,3 @@ "devDependencies": { | ||
"@types/semver": "^6.0.1", | ||
"@types/tar": "^4.0.0", | ||
"@types/unzipper": "^0.10.3", | ||
"chai": "^4.2.0", | ||
@@ -77,3 +77,3 @@ "mocha": "^6.1.4", | ||
}, | ||
"gitHead": "7528b5ae328540e9a64cb4437af6642d27f9cb50" | ||
"gitHead": "e32941d384b26d9e0bebde4f5a427a022195d1fc" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
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
58769
35
933
5
+ Addedunzipper@^0.10.11
+ Addedbalanced-match@1.0.2(transitive)
+ Addedbig-integer@1.6.52(transitive)
+ Addedbinary@0.3.0(transitive)
+ Addedbluebird@3.4.7(transitive)
+ Addedbrace-expansion@1.1.11(transitive)
+ Addedbuffer-indexof-polyfill@1.0.2(transitive)
+ Addedbuffers@0.1.1(transitive)
+ Addedchainsaw@0.1.0(transitive)
+ Addedconcat-map@0.0.1(transitive)
+ Addedcore-util-is@1.0.3(transitive)
+ Addedduplexer2@0.1.4(transitive)
+ Addedfs.realpath@1.0.0(transitive)
+ Addedfstream@1.0.12(transitive)
+ Addedglob@7.2.3(transitive)
+ Addedinflight@1.0.6(transitive)
+ Addedinherits@2.0.4(transitive)
+ Addedisarray@1.0.0(transitive)
+ Addedlistenercount@1.0.1(transitive)
+ Addedminimatch@3.1.2(transitive)
+ Addedonce@1.4.0(transitive)
+ Addedpath-is-absolute@1.0.1(transitive)
+ Addedprocess-nextick-args@2.0.1(transitive)
+ Addedreadable-stream@2.3.8(transitive)
+ Addedrimraf@2.7.1(transitive)
+ Addedsafe-buffer@5.1.2(transitive)
+ Addedsetimmediate@1.0.5(transitive)
+ Addedstring_decoder@1.1.1(transitive)
+ Addedtraverse@0.3.9(transitive)
+ Addedunzipper@0.10.14(transitive)
+ Addedutil-deprecate@1.0.2(transitive)
+ Addedwrappy@1.0.2(transitive)
- Removedtar@^4.4.8
- Removedchownr@1.1.4(transitive)
- Removedfs-minipass@1.2.7(transitive)
- Removedminipass@2.9.0(transitive)
- Removedminizlib@1.3.3(transitive)
- Removedsafe-buffer@5.2.1(transitive)
- Removedtar@4.4.19(transitive)
- Removedyallist@3.1.1(transitive)