@share2us/cli 0.1.0 → 0.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/install.js +12 -1
- package/package.json +21 -4
package/install.js
CHANGED
|
@@ -11,7 +11,18 @@ const https = require("https");
|
|
|
11
11
|
const { execFileSync } = require("child_process");
|
|
12
12
|
|
|
13
13
|
const REPO = process.env.SHARE2US_INSTALL_REPO || "share2us/cli";
|
|
14
|
-
|
|
14
|
+
|
|
15
|
+
// The release this npm version maps to. CI pins `share2usCliVersion` in
|
|
16
|
+
// package.json to the matching release tag at publish time, so a given npm
|
|
17
|
+
// version always installs the same binary. Falls back to the latest release.
|
|
18
|
+
function pinnedVersion() {
|
|
19
|
+
try {
|
|
20
|
+
return require("./package.json").share2usCliVersion || "latest";
|
|
21
|
+
} catch (e) {
|
|
22
|
+
return "latest";
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
const VERSION = process.env.SHARE2US_VERSION || pinnedVersion();
|
|
15
26
|
|
|
16
27
|
function fail(msg) {
|
|
17
28
|
console.error("share2us install: " + msg);
|
package/package.json
CHANGED
|
@@ -1,8 +1,19 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@share2us/cli",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.6",
|
|
4
|
+
"share2usCliVersion": "v20260719121715",
|
|
4
5
|
"description": "Share2Us CLI (s2u) — share files and text from your terminal, browser, or AI agent via one opaque, expiring link.",
|
|
5
|
-
"keywords": [
|
|
6
|
+
"keywords": [
|
|
7
|
+
"share2us",
|
|
8
|
+
"s2u",
|
|
9
|
+
"file-sharing",
|
|
10
|
+
"share",
|
|
11
|
+
"cli",
|
|
12
|
+
"p2p",
|
|
13
|
+
"qr",
|
|
14
|
+
"mcp",
|
|
15
|
+
"e2e"
|
|
16
|
+
],
|
|
6
17
|
"homepage": "https://share2.us",
|
|
7
18
|
"bugs": "https://github.com/share2us/cli/issues",
|
|
8
19
|
"repository": {
|
|
@@ -23,8 +34,14 @@
|
|
|
23
34
|
"bin/s2u.js",
|
|
24
35
|
"install.js"
|
|
25
36
|
],
|
|
26
|
-
"os": [
|
|
27
|
-
|
|
37
|
+
"os": [
|
|
38
|
+
"linux",
|
|
39
|
+
"darwin"
|
|
40
|
+
],
|
|
41
|
+
"cpu": [
|
|
42
|
+
"x64",
|
|
43
|
+
"arm64"
|
|
44
|
+
],
|
|
28
45
|
"engines": {
|
|
29
46
|
"node": ">=16"
|
|
30
47
|
}
|