@gaossr/kiri 0.1.6-darwin-arm64

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/LICENSE ADDED
@@ -0,0 +1,187 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction, and
10
+ distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by the
13
+ copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all other
16
+ entities that control, are controlled by, or are under common control with
17
+ that entity. For the purposes of this definition, "control" means (i) the
18
+ power, direct or indirect, to cause the direction or management of such
19
+ entity, whether by contract or otherwise, or (ii) ownership of fifty percent
20
+ (50%) or more of the outstanding shares, or (iii) beneficial ownership of
21
+ such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity exercising
24
+ permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation source,
28
+ and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical transformation
31
+ or translation of a Source form, including but not limited to compiled
32
+ object code, generated documentation, and conversions to other media types.
33
+
34
+ "Work" shall mean the work of authorship, whether in Source or Object form,
35
+ made available under the License, as indicated by a copyright notice that
36
+ is included in or attached to the work (an example is provided in the
37
+ Appendix below).
38
+
39
+ "Derivative Works" shall mean any work, whether in Source or Object form,
40
+ that is based on (or derived from) the Work and for which the editorial
41
+ revisions, annotations, elaborations, or other modifications represent,
42
+ as a whole, an original work of authorship. For the purposes of this License,
43
+ Derivative Works shall not include works that remain separable from, or
44
+ merely link (or bind by name) to the interfaces of, the Work and Derivative
45
+ Works thereof.
46
+
47
+ "Contribution" shall mean any work of authorship, including the original
48
+ version of the Work and any modifications or additions to that Work or
49
+ Derivative Works thereof, that is intentionally submitted to Licensor for
50
+ inclusion in the Work by the copyright owner or by an individual or Legal
51
+ Entity authorized to submit on behalf of the copyright owner. For the
52
+ purposes of this definition, "submitted" means any form of electronic,
53
+ verbal, or written communication sent to the Licensor or its representatives,
54
+ including but not limited to communication on electronic mailing lists,
55
+ source code control systems, and issue tracking systems that are managed by,
56
+ or on behalf of, the Licensor for the purpose of discussing and improving
57
+ the Work, but excluding communication that is conspicuously marked or
58
+ otherwise designated in writing by the copyright owner as "Not a Contribution."
59
+
60
+ "Contributor" shall mean Licensor and any individual or Legal Entity on
61
+ behalf of whom a Contribution has been received by Licensor and subsequently
62
+ incorporated within the Work.
63
+
64
+ 2. Grant of Copyright License. Subject to the terms and conditions of this
65
+ License, each Contributor hereby grants to You a perpetual, worldwide,
66
+ non-exclusive, no-charge, royalty-free, irrevocable copyright license to
67
+ reproduce, prepare Derivative Works of, publicly display, publicly perform,
68
+ sublicense, and distribute the Work and such Derivative Works in Source or
69
+ Object form.
70
+
71
+ 3. Grant of Patent License. Subject to the terms and conditions of this
72
+ License, each Contributor hereby grants to You a perpetual, worldwide,
73
+ non-exclusive, no-charge, royalty-free, irrevocable (except as stated in
74
+ this section) patent license to make, have made, use, offer to sell, sell,
75
+ import, and otherwise transfer the Work, where such license applies only
76
+ to those patent claims licensable by such Contributor that are necessarily
77
+ infringed by their Contribution(s) alone or by combination of their
78
+ Contribution(s) with the Work to which such Contribution(s) was submitted.
79
+ If You institute patent litigation against any entity (including a
80
+ cross-claim or counterclaim in a lawsuit) alleging that the Work or a
81
+ Contribution incorporated within the Work constitutes direct or contributory
82
+ patent infringement, then any patent licenses granted to You under this
83
+ License for that Work shall terminate as of the date such litigation is filed.
84
+
85
+ 4. Redistribution. You may reproduce and distribute copies of the Work or
86
+ Derivative Works thereof in any medium, with or without modifications, and
87
+ in Source or Object form, provided that You meet the following conditions:
88
+
89
+ (a) You must give any other recipients of the Work or Derivative Works a
90
+ copy of this License; and
91
+
92
+ (b) You must cause any modified files to carry prominent notices stating
93
+ that You changed the files; and
94
+
95
+ (c) You must retain, in the Source form of any Derivative Works that You
96
+ distribute, all copyright, patent, trademark, and attribution notices from
97
+ the Source form of the Work, excluding those notices that do not pertain
98
+ to any part of the Derivative Works; and
99
+
100
+ (d) If the Work includes a "NOTICE" text file as part of its distribution,
101
+ then any Derivative Works that You distribute must include a readable copy
102
+ of the attribution notices contained within such NOTICE file, excluding
103
+ those notices that do not pertain to any part of the Derivative Works, in
104
+ at least one of the following places: within a NOTICE text file distributed
105
+ as part of the Derivative Works; within the Source form or documentation,
106
+ if provided along with the Derivative Works; or, within a display generated
107
+ by the Derivative Works, if and wherever such third-party notices normally
108
+ appear. The contents of the NOTICE file are for informational purposes only
109
+ and do not modify the License. You may add Your own attribution notices
110
+ within Derivative Works that You distribute, alongside or as an addendum to
111
+ the NOTICE text from the Work, provided that such additional attribution
112
+ notices cannot be construed as modifying the License.
113
+
114
+ You may add Your own copyright statement to Your modifications and may
115
+ provide additional or different license terms and conditions for use,
116
+ reproduction, or distribution of Your modifications, or for any such
117
+ Derivative Works as a whole, provided Your use, reproduction, and
118
+ distribution of the Work otherwise complies with the conditions stated in
119
+ this License.
120
+
121
+ 5. Submission of Contributions. Unless You explicitly state otherwise, any
122
+ Contribution intentionally submitted for inclusion in the Work by You to the
123
+ Licensor shall be under the terms and conditions of this License, without
124
+ any additional terms or conditions. Notwithstanding the above, nothing herein
125
+ shall supersede or modify the terms of any separate license agreement you
126
+ may have executed with Licensor regarding such Contributions.
127
+
128
+ 6. Trademarks. This License does not grant permission to use the trade names,
129
+ trademarks, service marks, or product names of the Licensor, except as
130
+ required for reasonable and customary use in describing the origin of the
131
+ Work and reproducing the content of the NOTICE file.
132
+
133
+ 7. Disclaimer of Warranty. Unless required by applicable law or agreed to
134
+ in writing, Licensor provides the Work (and each Contributor provides its
135
+ Contributions) on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
136
+ KIND, either express or implied, including, without limitation, any warranties
137
+ or conditions of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR
138
+ A PARTICULAR PURPOSE. You are solely responsible for determining the
139
+ appropriateness of using or redistributing the Work and assume any risks
140
+ associated with Your exercise of permissions under this License.
141
+
142
+ 8. Limitation of Liability. In no event and under no legal theory, whether
143
+ in tort (including negligence), contract, or otherwise, unless required by
144
+ applicable law (such as deliberate and grossly negligent acts) or agreed to
145
+ in writing, shall any Contributor be liable to You for damages, including
146
+ any direct, indirect, special, incidental, or consequential damages of any
147
+ character arising as a result of this License or out of the use or inability
148
+ to use the Work (including but not limited to damages for loss of goodwill,
149
+ work stoppage, computer failure or malfunction, or any and all other
150
+ commercial damages or losses), even if such Contributor has been advised
151
+ of the possibility of such damages.
152
+
153
+ 9. Accepting Warranty or Additional Liability. While redistributing the Work
154
+ or Derivative Works thereof, You may choose to offer, and charge a fee for,
155
+ acceptance of support, warranty, indemnity, or other liability obligations
156
+ and/or rights consistent with this License. However, in accepting such
157
+ obligations, You may act only on Your own behalf and on Your sole
158
+ responsibility, not on behalf of any other Contributor, and only if You agree
159
+ to indemnify, defend, and hold each Contributor harmless for any liability
160
+ incurred by, or claims asserted against, such Contributor by reason of your
161
+ accepting any such warranty or additional liability.
162
+
163
+ END OF TERMS AND CONDITIONS
164
+
165
+ APPENDIX: How to apply the Apache License to your work.
166
+
167
+ To apply the Apache License to your work, attach the following boilerplate
168
+ notice, with the fields enclosed by brackets "[]" replaced with your own
169
+ identifying information. Do not include the brackets. The text should be
170
+ enclosed in the appropriate comment syntax for the file format. We also
171
+ recommend that a file or class name and description of purpose be included
172
+ on the same "printed page" as the copyright notice for easier identification
173
+ within third-party archives.
174
+
175
+ Copyright 2026 GaoSSR
176
+
177
+ Licensed under the Apache License, Version 2.0 (the "License");
178
+ you may not use this file except in compliance with the License.
179
+ You may obtain a copy of the License at
180
+
181
+ http://www.apache.org/licenses/LICENSE-2.0
182
+
183
+ Unless required by applicable law or agreed to in writing, software
184
+ distributed under the License is distributed on an "AS IS" BASIS,
185
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
186
+ See the License for the specific language governing permissions and
187
+ limitations under the License.
package/README.md ADDED
@@ -0,0 +1,63 @@
1
+ # Kiri npm Packaging
2
+
3
+ This directory packages Kiri for npm with precompiled macOS binaries.
4
+
5
+ After the npm package is published, users install it with:
6
+
7
+ ```bash
8
+ npm install -g @gaossr/kiri
9
+ ```
10
+
11
+ The root package name is `@gaossr/kiri`. It exposes one command:
12
+
13
+ - `ports`
14
+
15
+ The bin shim in `bin/` does not call Cargo and does not compile Rust locally. It locates the matching optional platform package and executes the precompiled binary from that package.
16
+
17
+ The package follows the same optional-dependency alias pattern used by `@openai/codex`: the installable root package depends on platform aliases, while the underlying published package name remains `@gaossr/kiri` with platform-specific prerelease versions.
18
+
19
+ Root package optional dependencies:
20
+
21
+ ```json
22
+ {
23
+ "@gaossr/kiri-darwin-arm64": "npm:@gaossr/kiri@<version>-darwin-arm64",
24
+ "@gaossr/kiri-darwin-x64": "npm:@gaossr/kiri@<version>-darwin-x64"
25
+ }
26
+ ```
27
+
28
+ Platform package vendor layout:
29
+
30
+ ```text
31
+ vendor/
32
+ darwin-arm64/
33
+ ports
34
+ darwin-x64/
35
+ ports
36
+ ```
37
+
38
+ If the matching binary is missing, the shim prints a clear error explaining that the npm package artifacts are missing and should be reinstalled.
39
+
40
+ Local checks:
41
+
42
+ ```bash
43
+ npm run check
44
+ npm run test
45
+ npm run pack:dry-run
46
+ ```
47
+
48
+ Build release tarballs from GitHub Release assets:
49
+
50
+ ```bash
51
+ node scripts/build-packages.js \
52
+ --version 0.1.6 \
53
+ --release-dir ../../dist \
54
+ --output-dir ../../dist/npm
55
+ ```
56
+
57
+ Publish order, after verifying tarball contents and npm authentication:
58
+
59
+ ```bash
60
+ npm publish ../../dist/npm/kiri-npm-darwin-arm64-0.1.6.tgz --tag darwin-arm64 --access public --registry https://registry.npmjs.org/
61
+ npm publish ../../dist/npm/kiri-npm-darwin-x64-0.1.6.tgz --tag darwin-x64 --access public --registry https://registry.npmjs.org/
62
+ npm publish ../../dist/npm/kiri-npm-0.1.6.tgz --access public --registry https://registry.npmjs.org/
63
+ ```
package/package.json ADDED
@@ -0,0 +1,25 @@
1
+ {
2
+ "name": "@gaossr/kiri",
3
+ "version": "0.1.6-darwin-arm64",
4
+ "description": "Kiri CLI for inspecting local development ports; installs the ports command (darwin-arm64)",
5
+ "license": "Apache-2.0",
6
+ "os": [
7
+ "darwin"
8
+ ],
9
+ "cpu": [
10
+ "arm64"
11
+ ],
12
+ "files": [
13
+ "LICENSE",
14
+ "README.md",
15
+ "vendor/"
16
+ ],
17
+ "engines": {
18
+ "node": ">=18"
19
+ },
20
+ "repository": {
21
+ "type": "git",
22
+ "url": "git+https://github.com/GaoSSR/kiri.git",
23
+ "directory": "packaging/npm"
24
+ }
25
+ }
Binary file