Comparing version 0.0.20200909 to 0.0.20210203
@@ -0,1 +1,2 @@ | ||
import { __importDefault, __importStar } from "tslib"; | ||
import { closeUplinks } from "@ndn/cli-common"; | ||
@@ -5,5 +6,5 @@ import { Name } from "@ndn/packet"; | ||
import { discoverVersion, fetch } from "@ndn/segmented-object"; | ||
import stdout from "stdout-stream"; | ||
import { segmentNumConvention, versionConvention } from "./common-args_browser.js"; | ||
const discoverVersionChoices = ["none", "cbp", "rdr"]; | ||
import _cjsDefaultImport0 from "stdout-stream"; const stdout = __importDefault(_cjsDefaultImport0).default; | ||
import { segmentNumConvention, versionConvention } from "./util_browser.js"; | ||
const discoverVersionChoices = { none: true, cbp: true, rdr: true }; | ||
async function main(args) { | ||
@@ -24,3 +25,3 @@ let name = new Name(args.name); | ||
} | ||
await fetch.toStream(name, stdout, { segmentNumConvention }); | ||
await fetch(name, { segmentNumConvention }).pipe(stdout); | ||
} | ||
@@ -41,3 +42,3 @@ export class GetSegmentedCommand { | ||
.option("ver", { | ||
choices: discoverVersionChoices, | ||
choices: Object.keys(discoverVersionChoices), | ||
default: "rdr", | ||
@@ -44,0 +45,0 @@ desc: ["version discovery method", |
@@ -1,4 +0,2 @@ | ||
import { createRequire } from "module"; | ||
const require = createRequire(import.meta.url); | ||
const { __importDefault } = require("tslib"); | ||
import { __importDefault, __importStar } from "tslib"; | ||
import { closeUplinks } from "@ndn/cli-common"; | ||
@@ -8,5 +6,5 @@ import { Name } from "@ndn/packet"; | ||
import { discoverVersion, fetch } from "@ndn/segmented-object"; | ||
const stdout = __importDefault(require("stdout-stream")).default; | ||
import { segmentNumConvention, versionConvention } from "./common-args_node.js"; | ||
const discoverVersionChoices = ["none", "cbp", "rdr"]; | ||
import _cjsDefaultImport0 from "stdout-stream"; const stdout = __importDefault(_cjsDefaultImport0).default; | ||
import { segmentNumConvention, versionConvention } from "./util_node.js"; | ||
const discoverVersionChoices = { none: true, cbp: true, rdr: true }; | ||
async function main(args) { | ||
@@ -27,3 +25,3 @@ let name = new Name(args.name); | ||
} | ||
await fetch.toStream(name, stdout, { segmentNumConvention }); | ||
await fetch(name, { segmentNumConvention }).pipe(stdout); | ||
} | ||
@@ -44,3 +42,3 @@ export class GetSegmentedCommand { | ||
.option("ver", { | ||
choices: discoverVersionChoices, | ||
choices: Object.keys(discoverVersionChoices), | ||
default: "rdr", | ||
@@ -47,0 +45,0 @@ desc: ["version discovery method", |
@@ -1,4 +0,9 @@ | ||
import { Arguments, Argv, CommandModule } from "yargs"; | ||
import { CommonArgs } from "./common-args"; | ||
declare type DiscoverVersionChoice = "none" | "cbp" | "rdr"; | ||
import type { Arguments, Argv, CommandModule } from "yargs"; | ||
import { CommonArgs } from "./util"; | ||
declare const discoverVersionChoices: { | ||
none: boolean; | ||
cbp: boolean; | ||
rdr: boolean; | ||
}; | ||
declare type DiscoverVersionChoice = keyof typeof discoverVersionChoices; | ||
interface Args extends CommonArgs { | ||
@@ -5,0 +10,0 @@ name: string; |
import yargs from "yargs"; | ||
import { applyCommonArgs } from "./common-args_browser.js"; | ||
// @ts-expect-error | ||
import { hideBin } from "yargs/helpers"; | ||
import { GetSegmentedCommand } from "./get-segmented_browser.js"; | ||
import { PutSegmentedCommand } from "./put-segmented_browser.js"; | ||
yargs | ||
import { applyCommonArgs } from "./util_browser.js"; | ||
yargs() | ||
.scriptName("ndncat") | ||
@@ -16,2 +18,2 @@ .option("convention1", { | ||
.demandCommand() | ||
.parse(); | ||
.parse(hideBin(process.argv)); |
@@ -1,9 +0,8 @@ | ||
import { createRequire } from "module"; | ||
const require = createRequire(import.meta.url); | ||
const { __importDefault } = require("tslib"); | ||
const yargs = __importDefault(require("yargs")).default; | ||
import { applyCommonArgs } from "./common-args_node.js"; | ||
import yargs from "yargs"; | ||
// @ts-expect-error | ||
import { hideBin } from "yargs/helpers"; | ||
import { GetSegmentedCommand } from "./get-segmented_node.js"; | ||
import { PutSegmentedCommand } from "./put-segmented_node.js"; | ||
yargs | ||
import { applyCommonArgs } from "./util_node.js"; | ||
yargs() | ||
.scriptName("ndncat") | ||
@@ -19,2 +18,2 @@ .option("convention1", { | ||
.demandCommand() | ||
.parse(); | ||
.parse(hideBin(process.argv)); |
import { serveMetadata } from "@ndn/rdr"; | ||
import { FileChunkSource, serve, serveVersioned, StreamChunkSource } from "@ndn/segmented-object"; | ||
import { segmentNumConvention, signer, versionConvention } from "./common-args_browser.js"; | ||
import { segmentNumConvention, signer, versionConvention } from "./util_browser.js"; | ||
function main({ name, rdr, ver, file, "chunk-size": chunkSize }) { | ||
@@ -5,0 +5,0 @@ const serveFunc = ver === "none" ? serve : serveVersioned; |
import { serveMetadata } from "@ndn/rdr"; | ||
import { FileChunkSource, serve, serveVersioned, StreamChunkSource } from "@ndn/segmented-object"; | ||
import { segmentNumConvention, signer, versionConvention } from "./common-args_node.js"; | ||
import { segmentNumConvention, signer, versionConvention } from "./util_node.js"; | ||
function main({ name, rdr, ver, file, "chunk-size": chunkSize }) { | ||
@@ -5,0 +5,0 @@ const serveFunc = ver === "none" ? serve : serveVersioned; |
@@ -1,3 +0,3 @@ | ||
import { Arguments, Argv, CommandModule } from "yargs"; | ||
import { CommonArgs } from "./common-args"; | ||
import type { Arguments, Argv, CommandModule } from "yargs"; | ||
import { CommonArgs } from "./util"; | ||
interface Args extends CommonArgs { | ||
@@ -4,0 +4,0 @@ name: string; |
{ | ||
"name": "@ndn/cat", | ||
"version": "0.0.20200909", | ||
"version": "0.0.20210203", | ||
"description": "NDNts: ndncat - netcat for NDN", | ||
@@ -25,13 +25,13 @@ "keywords": [ | ||
"dependencies": { | ||
"@ndn/cli-common": "0.0.20200909", | ||
"@ndn/naming-convention1": "0.0.20200909", | ||
"@ndn/naming-convention2": "0.0.20200909", | ||
"@ndn/packet": "0.0.20200909", | ||
"@ndn/rdr": "0.0.20200909", | ||
"@ndn/segmented-object": "0.0.20200909", | ||
"@ndn/cli-common": "0.0.20210203", | ||
"@ndn/naming-convention1": "0.0.20210203", | ||
"@ndn/naming-convention2": "0.0.20210203", | ||
"@ndn/packet": "0.0.20210203", | ||
"@ndn/rdr": "0.0.20210203", | ||
"@ndn/segmented-object": "0.0.20210203", | ||
"hard-rejection": "^2.1.0", | ||
"stdout-stream": "^1.4.1", | ||
"tslib": "^2.0.1", | ||
"yargs": "^15.4.1" | ||
"tslib": "^2.1.0", | ||
"yargs": "^16.2.0" | ||
} | ||
} |
@@ -34,3 +34,3 @@ # @ndn/cat | ||
```sh | ||
```bash | ||
dd if=/dev/urandom of=/tmp/1.bin bs=1M count=1 | ||
@@ -37,0 +37,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
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Debug access
Supply chain riskUses debug, reflection and dynamic code execution features.
Found 1 instance in 1 package
15024
339
0
2
+ Added@ndn/autoconfig@0.0.20210203(transitive)
+ Added@ndn/cli-common@0.0.20210203(transitive)
+ Added@ndn/endpoint@0.0.20210203(transitive)
+ Added@ndn/fw@0.0.20210203(transitive)
+ Added@ndn/keychain@0.0.20210203(transitive)
+ Added@ndn/l3face@0.0.20210203(transitive)
+ Added@ndn/lp@0.0.20210203(transitive)
+ Added@ndn/naming-convention1@0.0.20210203(transitive)
+ Added@ndn/naming-convention2@0.0.20210203(transitive)
+ Added@ndn/nfdmgmt@0.0.20210203(transitive)
+ Added@ndn/node-transport@0.0.20210203(transitive)
+ Added@ndn/packet@0.0.20210203(transitive)
+ Added@ndn/rdr@0.0.20210203(transitive)
+ Added@ndn/segmented-object@0.0.20210203(transitive)
+ Added@ndn/tlv@0.0.20210203(transitive)
+ Added@ndn/ws-transport@0.0.20210203(transitive)
+ Addedcliui@7.0.4(transitive)
+ Addedescalade@3.2.0(transitive)
+ Addedidb-keyval@5.1.5(transitive)
+ Addedit-pushable@1.4.0(transitive)
+ Addedsafari-14-idb-fix@1.0.6(transitive)
+ Addedthroat@6.0.2(transitive)
+ Addedwrap-ansi@7.0.0(transitive)
+ Addedy18n@5.0.8(transitive)
+ Addedyargs@16.2.0(transitive)
+ Addedyargs-parser@20.2.9(transitive)
- Removed@ndn/autoconfig@0.0.20200909(transitive)
- Removed@ndn/cli-common@0.0.20200909(transitive)
- Removed@ndn/endpoint@0.0.20200909(transitive)
- Removed@ndn/fw@0.0.20200909(transitive)
- Removed@ndn/keychain@0.0.20200909(transitive)
- Removed@ndn/l3face@0.0.20200909(transitive)
- Removed@ndn/lp@0.0.20200909(transitive)
- Removed@ndn/naming-convention1@0.0.20200909(transitive)
- Removed@ndn/naming-convention2@0.0.20200909(transitive)
- Removed@ndn/nfdmgmt@0.0.20200909(transitive)
- Removed@ndn/node-transport@0.0.20200909(transitive)
- Removed@ndn/packet@0.0.20200909(transitive)
- Removed@ndn/rdr@0.0.20200909(transitive)
- Removed@ndn/segmented-object@0.0.20200909(transitive)
- Removed@ndn/tlv@0.0.20200909(transitive)
- Removed@ndn/ws-transport@0.0.20200909(transitive)
- Removedcamelcase@5.3.1(transitive)
- Removedcliui@6.0.0(transitive)
- Removeddecamelize@1.2.0(transitive)
- Removedfind-up@4.1.0(transitive)
- Removedidb-keyval@3.2.0(transitive)
- Removedit-pushable@1.4.2(transitive)
- Removedlocate-path@5.0.0(transitive)
- Removedloglevel@1.9.2(transitive)
- Removedp-cancelable@2.1.1(transitive)
- Removedp-limit@2.3.0(transitive)
- Removedp-locate@4.1.0(transitive)
- Removedp-try@2.2.0(transitive)
- Removedpath-exists@4.0.0(transitive)
- Removedrequire-main-filename@2.0.0(transitive)
- Removedset-blocking@2.0.0(transitive)
- Removedthroat@5.0.0(transitive)
- Removedwhich-module@2.0.1(transitive)
- Removedwrap-ansi@6.2.0(transitive)
- Removedy18n@4.0.3(transitive)
- Removedyargs@15.4.1(transitive)
- Removedyargs-parser@18.1.3(transitive)
Updated@ndn/cli-common@0.0.20210203
Updated@ndn/packet@0.0.20210203
Updated@ndn/rdr@0.0.20210203
Updatedtslib@^2.1.0
Updatedyargs@^16.2.0