ajp-protocol 0.2.1 → 0.2.2
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/.github/workflows/publish.yml +33 -1
- package/cli/package.json +13 -4
- package/package.json +1 -1
|
@@ -44,4 +44,36 @@ jobs:
|
|
|
44
44
|
# publish rights, configured as a trusted publisher on npmjs.com against
|
|
45
45
|
# this repository and this workflow filename. Provenance attestations are
|
|
46
46
|
# generated automatically, so --provenance is not passed.
|
|
47
|
-
|
|
47
|
+
# Skip rather than fail when this version is already on npm. A tag may
|
|
48
|
+
# exist to release a sibling package in this repo, and a red run that
|
|
49
|
+
# actually means "nothing to publish here" trains people to ignore red
|
|
50
|
+
# runs. The log says which happened.
|
|
51
|
+
- name: Publish the protocol package if its version is new
|
|
52
|
+
run: |
|
|
53
|
+
NAME=$(node -p "require('./package.json').name")
|
|
54
|
+
VERSION=$(node -p "require('./package.json').version")
|
|
55
|
+
if npm view "$NAME@$VERSION" version >/dev/null 2>&1; then
|
|
56
|
+
echo "::notice::$NAME@$VERSION is already published — skipping. Bump package.json to release it."
|
|
57
|
+
else
|
|
58
|
+
echo "Publishing $NAME@$VERSION"
|
|
59
|
+
npm publish --access public
|
|
60
|
+
fi
|
|
61
|
+
|
|
62
|
+
# The CLI is a second package in this repo with its own version. Publish it
|
|
63
|
+
# from the same tag, but only when its version is actually new — otherwise
|
|
64
|
+
# every release after an unchanged CLI would fail on "cannot publish over
|
|
65
|
+
# the previously published version".
|
|
66
|
+
#
|
|
67
|
+
# A skip and a publish must not look alike in the log: one means "nothing
|
|
68
|
+
# to do", the other means "shipped".
|
|
69
|
+
- name: Publish the CLI if its version is new
|
|
70
|
+
working-directory: cli
|
|
71
|
+
run: |
|
|
72
|
+
NAME=$(node -p "require('./package.json').name")
|
|
73
|
+
VERSION=$(node -p "require('./package.json').version")
|
|
74
|
+
if npm view "$NAME@$VERSION" version >/dev/null 2>&1; then
|
|
75
|
+
echo "::notice::$NAME@$VERSION is already published — skipping. Bump cli/package.json to release it."
|
|
76
|
+
else
|
|
77
|
+
echo "Publishing $NAME@$VERSION"
|
|
78
|
+
npm publish --access public
|
|
79
|
+
fi
|
package/cli/package.json
CHANGED
|
@@ -1,17 +1,26 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ilucky21c/ajp-cli",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "CLI for the Agent Job Protocol
|
|
3
|
+
"version": "0.1.1",
|
|
4
|
+
"description": "CLI for the Agent Job Protocol \u2014 hire agents and check job status from the terminal",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
7
7
|
"ajp": "./index.js"
|
|
8
8
|
},
|
|
9
|
-
"engines": {
|
|
9
|
+
"engines": {
|
|
10
|
+
"node": ">=18"
|
|
11
|
+
},
|
|
10
12
|
"repository": {
|
|
11
13
|
"type": "git",
|
|
12
14
|
"url": "git+https://github.com/ilucky21c/ajp-protocol.git",
|
|
13
15
|
"directory": "cli"
|
|
14
16
|
},
|
|
15
|
-
"keywords": [
|
|
17
|
+
"keywords": [
|
|
18
|
+
"ajp",
|
|
19
|
+
"agent-job-protocol",
|
|
20
|
+
"provenance",
|
|
21
|
+
"ai",
|
|
22
|
+
"agents",
|
|
23
|
+
"cli"
|
|
24
|
+
],
|
|
16
25
|
"license": "MIT"
|
|
17
26
|
}
|