@osdlc/typed-git 0.5.0 → 0.5.3
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/CHANGELOG.md +83 -36
- package/LICENSE-APACHE +202 -0
- package/README.md +133 -30
- package/async.ts +109 -32
- package/backend.ts +57 -12
- package/client.ts +18 -8
- package/dist/async.d.ts +59 -23
- package/dist/async.d.ts.map +1 -1
- package/dist/async.js +87 -29
- package/dist/backend.d.ts +50 -9
- package/dist/backend.d.ts.map +1 -1
- package/dist/backend.js +25 -3
- package/dist/client.d.ts +10 -7
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +10 -7
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/outcome.d.ts +6 -1
- package/dist/outcome.d.ts.map +1 -1
- package/dist/remote-url.d.ts +3 -0
- package/dist/remote-url.d.ts.map +1 -1
- package/dist/remote-url.js +3 -0
- package/dist/soft.d.ts +7 -1
- package/dist/soft.d.ts.map +1 -1
- package/dist/soft.js +7 -1
- package/dist/sync.d.ts +74 -24
- package/dist/sync.d.ts.map +1 -1
- package/dist/sync.js +99 -28
- package/dist/testing.d.ts +54 -26
- package/dist/testing.d.ts.map +1 -1
- package/dist/testing.js +11 -4
- package/dist/verbs.d.ts +163 -41
- package/dist/verbs.d.ts.map +1 -1
- package/dist/verbs.js +342 -83
- package/index.ts +2 -2
- package/outcome.ts +13 -5
- package/package.json +11 -6
- package/remote-url.ts +3 -0
- package/soft.ts +7 -1
- package/sync.ts +114 -31
- package/testing.ts +64 -32
- package/verbs.ts +427 -103
- /package/{LICENSE → LICENSE-MIT} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,25 +1,68 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
3
|
+
## 0.5.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 4d13bd9: The Apache-2.0 licence file now names the same copyright holder as the MIT file: sksizer. It said "Sizer LLC".
|
|
8
|
+
|
|
9
|
+
## 0.5.2
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Updated dependencies [ac5f0d1]
|
|
14
|
+
- @osdlc/command-seam@0.8.0
|
|
15
|
+
|
|
16
|
+
## 0.5.1
|
|
17
|
+
|
|
18
|
+
### Patch Changes
|
|
19
|
+
|
|
20
|
+
- e6af15f: The fixes from the first-release review. CI published 0.5.0 from the code as it was moved into this repository, before these fixes. This release changes 0.5.0 as listed below. Some changes break callers of 0.5.0. They are marked `Breaking:`. This is an exception to the rule that breaking changes ship in a new minor: the version stays on 0.5 to match the Rust twin, the crate `typed-git`, which keeps the same major and minor version.
|
|
21
|
+
|
|
22
|
+
- Breaking: the licence is now `MIT OR Apache-2.0`, with `LICENSE-MIT` and `LICENSE-APACHE`. 0.5.0 was `MIT`.
|
|
23
|
+
- `engines.node` is now `^22.22.2 || ^24.15.0 || >=26.0.0`, the range `hosted-git-info` needs.
|
|
24
|
+
- The package is supported on macOS, Linux and Windows. CI runs Linux and macOS. Windows is not tested in CI yet. The tested minimum git is the oldest git CI runs: 2.55.0 on 2026-10-20.
|
|
25
|
+
- Breaking: 42 verbs throw a `TypeError` before git runs when a ref, remote, URL, path, ref pattern or config key argument starts with `-`. This stops a value like `--upload-pack=...` or `--output=<file>` from reaching git as an option. In `log` this covers `rev`, `range` and each `notRefs` entry. In `diffNameOnly` and `diffStat` it covers each `rangeArgs` token. The message is `typed-git: <verb>: <param> must not start with "-" (got "...")`. `try` and `soft` do not catch it. On `AsyncGit` with `cliBackend` it is a rejection, and a backend that is not the CLI gets the request unchecked. `revParse` is not guarded, because it passes flags on by design. Paths still go after `--`. To pass a path that starts with `-`, write `./-name`. For the previous branch, write `@{-1}` instead of `-` in `checkout` and `merge`.
|
|
26
|
+
- `grep` passes its pattern with `-e`, so a pattern that starts with `-` is searched for. Before, git read it as an option.
|
|
27
|
+
- Breaking: `diffText` follows the failure contract. It declares no absent exit codes. A bad rev (exit 128) and a directory outside a repository (exit 129) throw `CommandFailed`, and `git.try.diffText` gives `{ ok: false }`. An empty string now means only that nothing differs. Callers that read `""` as "no diff" on a failure must handle the throw.
|
|
28
|
+
- Breaking: `diffAddedFile` follows the contract. Exit 1 with output is success. Exit 1 with empty output (a path git cannot read) and exit 2 throw `CommandFailed`. Before, both gave `""`.
|
|
29
|
+
- Breaking: `soft.configRemoveSection` is removed, from the soft table and the `Soft` type. The plain verb still returns `false` when there is no such section.
|
|
30
|
+
- Breaking: `gate` and the `GitVerb` type are no longer exported from `.` or `./client`. `REF_FORMAT` and `parseRefRows` stay.
|
|
31
|
+
- Breaking: `checkoutSide(side, [])` returns without running git. Before, it threw on git's exit 128.
|
|
32
|
+
- `merge`, `rebase` and `rebaseContinue` run with `LC_ALL=C`, over the client, backend and call `env`. `fastForward`, `alreadyUpToDate` and `conflicts` no longer change with the caller's locale.
|
|
33
|
+
- `remotes()` on `Git` and `AsyncGit`, soft form too. `remote()` still works and is deprecated. It will be removed at 1.0.
|
|
34
|
+
- Call options (`timeoutMs`, `env`, and `signal` on the async side) are now taken by every method: `diffText(rev?, opts)`, `diffAddedFile(relPath, opts)` and `revParse(...args, opts)`, where a trailing non-string argument is the options object.
|
|
35
|
+
- New exported types from `.` and `./client`: `StatusEntry`, `CleanOptions`, `DiffCheckOptions`, `DiffCheckResult`, `CommitFlags` and `DiffTextOptions`.
|
|
36
|
+
- `./testing` exports `MakeOriginAndCheckoutOptions`, `OriginAndCheckout`, `MakeBareAndWorkerOptions` and `BareAndWorker`.
|
|
37
|
+
- `GitBackend`, `GitRequest`, `GitResults` and `partialBackend` are marked `@experimental`. They may change in a minor release, because each new verb adds a request kind. The `configGet` and `remoteGetUrl` requests now carry `scope` and `push`. A backend must honour them or reject.
|
|
38
|
+
- The README is rewritten. It now says that `./client` leaves out the URL parsers and the checkout walks, and so does not load `hosted-git-info`.
|
|
39
|
+
- `configGet` takes `{ scope }` (`'local'`, `'global'` or `'system'`), the same scope `configSet` takes. The new `ConfigScope` type names it.
|
|
40
|
+
- Breaking: `configGet` throws a `TypeError` before git runs when the key has no section or no name: no `.`, or a leading or trailing `.`. git exits 1 for such a key, and 0.5.0 read that as unset and returned `null`. `configGetAll` and `configGetBool` check the same.
|
|
41
|
+
- `configGetAll(key, { scope })` returns every value of a key, verbatim, and `[]` when the key is unset.
|
|
42
|
+
- `configGetBool(key, { scope })` returns the key read as a boolean by git (`config --type=bool`), and `null` when it is unset. A value git cannot read as a boolean throws.
|
|
43
|
+
- `remoteGetUrl` takes `{ push }` for the push URL. `remoteGetUrls(name, { push })` returns every URL of a remote, and `[]` for an unknown remote.
|
|
44
|
+
- `remoteHead(remote)` asks the remote for the branch its HEAD points at (`ls-remote --symref`). It returns the full refname, or `null` when the remote names none.
|
|
45
|
+
- `gitDir()` returns this worktree's own `.git` directory as an absolute path, or `null` outside a repository.
|
|
46
|
+
- `clone` takes `mirror`, `singleBranch` and `noTags`. `fetch` takes `depth` and `noTags`. With `mirror`, `noTags` has no effect and `singleBranch` holds for the clone only.
|
|
47
|
+
- Breaking: `clone` and `fetch` throw a `TypeError` before git runs when `depth` is not a positive integer. Before, git refused it and the call threw `CommandFailed`.
|
|
48
|
+
- Call options take `maxOutputBytes` on both clients, and `cliBackend` passes it to its runner.
|
|
49
|
+
- Breaking: a result whose output was cut short (`outputIncomplete`, at the output cap or a timeout) now throws `CommandFailed`, from every verb and from `rawChecked` on both clients. Before, the cut-short output was parsed as the answer.
|
|
50
|
+
- New exported types from `.` and `./client`: `ConfigScope`, `ConfigGetOptions` and `RemoteGetUrlOptions`.
|
|
51
|
+
|
|
52
|
+
## 0.5.0
|
|
53
|
+
|
|
54
|
+
Published to npm on 2026-10-20 by CI, from the code as it was moved into
|
|
55
|
+
osdlc/osdlc. Licence `MIT`. It was the first npm release. The package was
|
|
56
|
+
first called `easy-git` and was never published under that name.
|
|
57
|
+
|
|
58
|
+
Two additions were made at the move:
|
|
16
59
|
|
|
17
60
|
- `checkIgnoreVerbose(paths)` (sync and async): the matching ignore rule for each path, as
|
|
18
61
|
`{ path, source, line, pattern }` (`git check-ignore -v --stdin -z`).
|
|
19
62
|
- `diffTree` option `findRenames` (`-M`): report a move as one rename record with its source
|
|
20
63
|
path. Off by default, so existing calls are unchanged.
|
|
21
64
|
|
|
22
|
-
|
|
65
|
+
The rest of 0.5.0 was made before the move:
|
|
23
66
|
|
|
24
67
|
### Changed
|
|
25
68
|
|
|
@@ -83,9 +126,13 @@ back as `ok: false`; only a git failure throws.
|
|
|
83
126
|
`diffStat({ rangeArgs, paths })` — the `git diff --stat` summary as raw
|
|
84
127
|
stdout, on both clients.
|
|
85
128
|
|
|
86
|
-
##
|
|
129
|
+
## History before the first npm release
|
|
87
130
|
|
|
88
|
-
|
|
131
|
+
These versions were not published.
|
|
132
|
+
|
|
133
|
+
### [0.4.0] - 2026-09-12 (unpublished)
|
|
134
|
+
|
|
135
|
+
#### Added
|
|
89
136
|
|
|
90
137
|
`mainCheckout()` — the primary checkout that owns this working directory, or
|
|
91
138
|
null outside a repository. Correct from inside a linked worktree, which is
|
|
@@ -146,7 +193,7 @@ against real paths silently misses the files most worth attention.
|
|
|
146
193
|
conflict and a name it cannot merge both exit 1, and only stdout separates
|
|
147
194
|
them.
|
|
148
195
|
|
|
149
|
-
|
|
196
|
+
#### Changed
|
|
150
197
|
|
|
151
198
|
- `Git.push` / `AsyncGit.push` accept `forceWithLease: string`, matching the
|
|
152
199
|
verb, which has taken the pinned `<ref>:<sha>` form since it was written.
|
|
@@ -155,7 +202,7 @@ them.
|
|
|
155
202
|
`--force-with-lease` compares against the remote-tracking ref, which a fetch
|
|
156
203
|
earlier in the same process may have just updated.
|
|
157
204
|
|
|
158
|
-
|
|
205
|
+
#### Fixed
|
|
159
206
|
|
|
160
207
|
A git that never ran read as a declared absence. The subprocess seam reports
|
|
161
208
|
`exitCode: 1` for a child that never gave one — `git` missing from PATH, a
|
|
@@ -182,9 +229,9 @@ verb's bare argv, dropping a repository-bound client's `--git-dir`/`--work-tree`
|
|
|
182
229
|
prefix that every exit-code failure already reports. `GitVerb.parse` now takes
|
|
183
230
|
the argv that ran as its second argument and those sites report it.
|
|
184
231
|
|
|
185
|
-
|
|
232
|
+
### [0.3.0] - 2026-09-01 (unpublished)
|
|
186
233
|
|
|
187
|
-
|
|
234
|
+
#### Added — integration verbs, and a fourth thing an exit code can mean
|
|
188
235
|
|
|
189
236
|
`merge`, `mergeAbort`, `rebase`, `rebaseAbort`, `rebaseContinue`,
|
|
190
237
|
`lsFilesUnmerged`, `checkout`, `checkoutSide`.
|
|
@@ -216,7 +263,7 @@ resolver that assumes both-modified deletes files.
|
|
|
216
263
|
`checkoutSide` documents the edge git leaves: on a path that is not conflicted
|
|
217
264
|
it exits 0 and does nothing, so there is no error to catch.
|
|
218
265
|
|
|
219
|
-
|
|
266
|
+
#### Changed
|
|
220
267
|
|
|
221
268
|
- **`push` accepts a pinned lease.** `forceWithLease` widened from `boolean`
|
|
222
269
|
to `boolean | string`; a string becomes `--force-with-lease=<ref>:<sha>`.
|
|
@@ -224,9 +271,9 @@ it exits 0 and does nothing, so there is no error to catch.
|
|
|
224
271
|
background fetch can quietly bring that up to date — after which the lease
|
|
225
272
|
vetoes nothing and a concurrent push is erased.
|
|
226
273
|
|
|
227
|
-
|
|
274
|
+
### [0.2.0] - 2026-09-01 (unpublished)
|
|
228
275
|
|
|
229
|
-
|
|
276
|
+
#### Breaking — queries now throw on failure
|
|
230
277
|
|
|
231
278
|
A query used to fold every non-zero exit into its absence value (`null`, `[]`,
|
|
232
279
|
`false`). That made "git broke" indistinguishable from "nothing there", and
|
|
@@ -300,7 +347,7 @@ Specific behaviour changes to check for at your call sites:
|
|
|
300
347
|
a failure for `revParse`. A `partialBackend` that answered `revParse` on
|
|
301
348
|
their behalf must handle the new kinds.
|
|
302
349
|
|
|
303
|
-
|
|
350
|
+
#### Added
|
|
304
351
|
|
|
305
352
|
- **Tier 1 verbs**, all declaring `absent: []` — no exit code is an answer, so
|
|
306
353
|
a failure cannot read as an empty result:
|
|
@@ -421,10 +468,10 @@ Specific behaviour changes to check for at your call sites:
|
|
|
421
468
|
on a bare store, where nothing is ever signed.
|
|
422
469
|
- Call options (`timeoutMs`, `signal`, `env`) on every client method, not just
|
|
423
470
|
`lsRemote` / `fetch` / `push`.
|
|
424
|
-
- Subpath exports:
|
|
425
|
-
`hosted-git-info`) and
|
|
471
|
+
- Subpath exports: `easy-git/client` (the clients without
|
|
472
|
+
`hosted-git-info`) and `easy-git/testing` (a git fixture builder).
|
|
426
473
|
|
|
427
|
-
|
|
474
|
+
#### Known limits
|
|
428
475
|
|
|
429
476
|
- **Exit 128 is overloaded.** For `showAtRev` and `logSubject`, git spells both "not there" and "not
|
|
430
477
|
a repository" as 128, so those two verbs must declare it absent and cannot separate absence from
|
|
@@ -448,7 +495,7 @@ Specific behaviour changes to check for at your call sites:
|
|
|
448
495
|
*where is the root?* but not *which files are here?* — but a null-check on
|
|
449
496
|
the first does not make the second line safe.
|
|
450
497
|
|
|
451
|
-
|
|
498
|
+
### [0.1.0] - 2026-08-29 (unpublished)
|
|
452
499
|
|
|
453
500
|
Version 0.1.0 has never been published. Entries below are dated by commit.
|
|
454
501
|
|
|
@@ -456,7 +503,7 @@ The client and its subprocess seam were written in-place inside an
|
|
|
456
503
|
application (`lib/services/git/easy.ts` and `lib/util/command.ts`) and
|
|
457
504
|
promoted into a standalone package on 2026-07-20.
|
|
458
505
|
|
|
459
|
-
|
|
506
|
+
#### Added
|
|
460
507
|
|
|
461
508
|
- **`AsyncGit`, the awaitable client.** Same surface as `Git`, promised.
|
|
462
509
|
For callers that must not block — a server, or work that fans out
|
|
@@ -492,34 +539,34 @@ promoted into a standalone package on 2026-07-20.
|
|
|
492
539
|
match, `""` for an absent committish) to `null`, matching the query
|
|
493
540
|
contract (2026-08-26).
|
|
494
541
|
|
|
495
|
-
|
|
542
|
+
#### Changed
|
|
496
543
|
|
|
497
|
-
- **The subprocess seam moved to `@
|
|
544
|
+
- **The subprocess seam moved to `command-seam` (now `@osdlc/command-seam`)**, which this
|
|
498
545
|
package now depends on and re-exports. The seam is not git-specific, and
|
|
499
546
|
the sync and async doors living in separate homes was an accident of
|
|
500
547
|
extraction order. Callers importing `CommandRunner`, `spawnRunner`,
|
|
501
|
-
`runChecked`, or `CommandFailed` from
|
|
548
|
+
`runChecked`, or `CommandFailed` from `easy-git` are
|
|
502
549
|
unaffected — the re-export keeps one `CommandFailed` class end-to-end
|
|
503
550
|
(2026-08-29).
|
|
504
551
|
- Optional fields across the public API are spelled `?: T | undefined`
|
|
505
552
|
rather than `?: T`, so options built by spreading a caller's own
|
|
506
553
|
optionals typecheck under `exactOptionalPropertyTypes` (2026-08-29).
|
|
507
554
|
- Promoted from application-internal modules into the standalone package
|
|
508
|
-
|
|
555
|
+
`easy-git`, with no re-export shim at the old paths
|
|
509
556
|
(2026-07-20).
|
|
510
557
|
- The package tsconfig now extends a shared base rather than standing
|
|
511
558
|
alone, so its strictness matches its consumers (2026-08-23).
|
|
512
559
|
|
|
513
|
-
|
|
560
|
+
#### Fixed
|
|
514
561
|
|
|
515
562
|
- **`timeoutMs` was plumbed in an `exactOptionalPropertyTypes`-unsafe way**
|
|
516
563
|
through the client (2026-07-19).
|
|
517
564
|
|
|
518
565
|
The subprocess-level fixes — Bun's `bun test` stdio corruption, timeouts
|
|
519
566
|
that never fired, a failed spawn reported as a silent exit 1 — moved with
|
|
520
|
-
the seam and are recorded in `@
|
|
567
|
+
the seam and are recorded in `@osdlc/command-seam`'s changelog.
|
|
521
568
|
|
|
522
|
-
|
|
569
|
+
#### Known issues
|
|
523
570
|
|
|
524
571
|
- `hosted-git-info` types are declared locally rather than taken from
|
|
525
572
|
DefinitelyTyped, whose copy predates the current API.
|
package/LICENSE-APACHE
ADDED
|
@@ -0,0 +1,202 @@
|
|
|
1
|
+
|
|
2
|
+
Apache License
|
|
3
|
+
Version 2.0, January 2004
|
|
4
|
+
http://www.apache.org/licenses/
|
|
5
|
+
|
|
6
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
7
|
+
|
|
8
|
+
1. Definitions.
|
|
9
|
+
|
|
10
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
11
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
12
|
+
|
|
13
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
14
|
+
the copyright owner that is granting the License.
|
|
15
|
+
|
|
16
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
17
|
+
other entities that control, are controlled by, or are under common
|
|
18
|
+
control with that entity. For the purposes of this definition,
|
|
19
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
20
|
+
direction or management of such entity, whether by contract or
|
|
21
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
22
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
23
|
+
|
|
24
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
25
|
+
exercising permissions granted by this License.
|
|
26
|
+
|
|
27
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
28
|
+
including but not limited to software source code, documentation
|
|
29
|
+
source, and configuration files.
|
|
30
|
+
|
|
31
|
+
"Object" form shall mean any form resulting from mechanical
|
|
32
|
+
transformation or translation of a Source form, including but
|
|
33
|
+
not limited to compiled object code, generated documentation,
|
|
34
|
+
and conversions to other media types.
|
|
35
|
+
|
|
36
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
37
|
+
Object form, made available under the License, as indicated by a
|
|
38
|
+
copyright notice that is included in or attached to the work
|
|
39
|
+
(an example is provided in the Appendix below).
|
|
40
|
+
|
|
41
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
42
|
+
form, that is based on (or derived from) the Work and for which the
|
|
43
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
44
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
45
|
+
of this License, Derivative Works shall not include works that remain
|
|
46
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
47
|
+
the Work and Derivative Works thereof.
|
|
48
|
+
|
|
49
|
+
"Contribution" shall mean any work of authorship, including
|
|
50
|
+
the original version of the Work and any modifications or additions
|
|
51
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
52
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
53
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
54
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
55
|
+
means any form of electronic, verbal, or written communication sent
|
|
56
|
+
to the Licensor or its representatives, including but not limited to
|
|
57
|
+
communication on electronic mailing lists, source code control systems,
|
|
58
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
59
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
60
|
+
excluding communication that is conspicuously marked or otherwise
|
|
61
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
62
|
+
|
|
63
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
64
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
65
|
+
subsequently incorporated within the Work.
|
|
66
|
+
|
|
67
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
68
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
69
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
70
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
71
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
72
|
+
Work and such Derivative Works in Source or Object form.
|
|
73
|
+
|
|
74
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
75
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
76
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
77
|
+
(except as stated in this section) patent license to make, have made,
|
|
78
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
79
|
+
where such license applies only to those patent claims licensable
|
|
80
|
+
by such Contributor that are necessarily infringed by their
|
|
81
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
82
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
83
|
+
institute patent litigation against any entity (including a
|
|
84
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
85
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
86
|
+
or contributory patent infringement, then any patent licenses
|
|
87
|
+
granted to You under this License for that Work shall terminate
|
|
88
|
+
as of the date such litigation is filed.
|
|
89
|
+
|
|
90
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
91
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
92
|
+
modifications, and in Source or Object form, provided that You
|
|
93
|
+
meet the following conditions:
|
|
94
|
+
|
|
95
|
+
(a) You must give any other recipients of the Work or
|
|
96
|
+
Derivative Works a copy of this License; and
|
|
97
|
+
|
|
98
|
+
(b) You must cause any modified files to carry prominent notices
|
|
99
|
+
stating that You changed the files; and
|
|
100
|
+
|
|
101
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
102
|
+
that You distribute, all copyright, patent, trademark, and
|
|
103
|
+
attribution notices from the Source form of the Work,
|
|
104
|
+
excluding those notices that do not pertain to any part of
|
|
105
|
+
the Derivative Works; and
|
|
106
|
+
|
|
107
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
108
|
+
distribution, then any Derivative Works that You distribute must
|
|
109
|
+
include a readable copy of the attribution notices contained
|
|
110
|
+
within such NOTICE file, excluding those notices that do not
|
|
111
|
+
pertain to any part of the Derivative Works, in at least one
|
|
112
|
+
of the following places: within a NOTICE text file distributed
|
|
113
|
+
as part of the Derivative Works; within the Source form or
|
|
114
|
+
documentation, if provided along with the Derivative Works; or,
|
|
115
|
+
within a display generated by the Derivative Works, if and
|
|
116
|
+
wherever such third-party notices normally appear. The contents
|
|
117
|
+
of the NOTICE file are for informational purposes only and
|
|
118
|
+
do not modify the License. You may add Your own attribution
|
|
119
|
+
notices within Derivative Works that You distribute, alongside
|
|
120
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
121
|
+
that such additional attribution notices cannot be construed
|
|
122
|
+
as modifying the License.
|
|
123
|
+
|
|
124
|
+
You may add Your own copyright statement to Your modifications and
|
|
125
|
+
may provide additional or different license terms and conditions
|
|
126
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
127
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
128
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
129
|
+
the conditions stated in this License.
|
|
130
|
+
|
|
131
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
132
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
133
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
134
|
+
this License, without any additional terms or conditions.
|
|
135
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
136
|
+
the terms of any separate license agreement you may have executed
|
|
137
|
+
with Licensor regarding such Contributions.
|
|
138
|
+
|
|
139
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
140
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
141
|
+
except as required for reasonable and customary use in describing the
|
|
142
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
143
|
+
|
|
144
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
145
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
146
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
147
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
148
|
+
implied, including, without limitation, any warranties or conditions
|
|
149
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
150
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
151
|
+
appropriateness of using or redistributing the Work and assume any
|
|
152
|
+
risks associated with Your exercise of permissions under this License.
|
|
153
|
+
|
|
154
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
155
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
156
|
+
unless required by applicable law (such as deliberate and grossly
|
|
157
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
158
|
+
liable to You for damages, including any direct, indirect, special,
|
|
159
|
+
incidental, or consequential damages of any character arising as a
|
|
160
|
+
result of this License or out of the use or inability to use the
|
|
161
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
162
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
163
|
+
other commercial damages or losses), even if such Contributor
|
|
164
|
+
has been advised of the possibility of such damages.
|
|
165
|
+
|
|
166
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
167
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
168
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
169
|
+
or other liability obligations and/or rights consistent with this
|
|
170
|
+
License. However, in accepting such obligations, You may act only
|
|
171
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
172
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
173
|
+
defend, and hold each Contributor harmless for any liability
|
|
174
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
175
|
+
of your accepting any such warranty or additional liability.
|
|
176
|
+
|
|
177
|
+
END OF TERMS AND CONDITIONS
|
|
178
|
+
|
|
179
|
+
APPENDIX: How to apply the Apache License to your work.
|
|
180
|
+
|
|
181
|
+
To apply the Apache License to your work, attach the following
|
|
182
|
+
boilerplate notice, with the fields enclosed by brackets "[]"
|
|
183
|
+
replaced with your own identifying information. (Don't include
|
|
184
|
+
the brackets!) The text should be enclosed in the appropriate
|
|
185
|
+
comment syntax for the file format. We also recommend that a
|
|
186
|
+
file or class name and description of purpose be included on the
|
|
187
|
+
same "printed page" as the copyright notice for easier
|
|
188
|
+
identification within third-party archives.
|
|
189
|
+
|
|
190
|
+
Copyright 2026 sksizer
|
|
191
|
+
|
|
192
|
+
Licensed under the Apache License, Version 2.0 (the "License");
|
|
193
|
+
you may not use this file except in compliance with the License.
|
|
194
|
+
You may obtain a copy of the License at
|
|
195
|
+
|
|
196
|
+
http://www.apache.org/licenses/LICENSE-2.0
|
|
197
|
+
|
|
198
|
+
Unless required by applicable law or agreed to in writing, software
|
|
199
|
+
distributed under the License is distributed on an "AS IS" BASIS,
|
|
200
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
201
|
+
See the License for the specific language governing permissions and
|
|
202
|
+
limitations under the License.
|