@intentset/publisher 0.6.1 → 0.7.0
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/README.md +39 -0
- package/dist/generate.d.ts +2 -2
- package/dist/generate.js +1 -1
- package/dist/help.d.ts +1 -1
- package/dist/help.js +1 -1
- package/package.json +10 -3
- package/src/generate.ts +2 -2
- package/src/help.ts +1 -1
package/README.md
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# @intentset/publisher
|
|
2
|
+
|
|
3
|
+
Publishes reviewed knowledge for one audience and release (`spec/publication.md`): it projects the graph deny by
|
|
4
|
+
default, checks that no excluded record's title or path leaks, and writes Markset documents with their provenance,
|
|
5
|
+
an index, retrieval chunks, and `help.json`, the tips a product shows beside its controls.
|
|
6
|
+
|
|
7
|
+
## Install
|
|
8
|
+
|
|
9
|
+
```sh
|
|
10
|
+
npm install @intentset/publisher
|
|
11
|
+
pnpm add @intentset/publisher
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## Example
|
|
15
|
+
|
|
16
|
+
Most repositories publish through the CLI, `@intentset/cli`:
|
|
17
|
+
|
|
18
|
+
```sh
|
|
19
|
+
npx -p @intentset/cli intentset publish --visibility customer --audience teacher --product PRD-LANTERN \
|
|
20
|
+
--release pilot-1 --role teacher --edition standard --out published/ --html
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
With pnpm, `pnpm dlx --package=@intentset/cli intentset …`, or `pnpm exec intentset …` once `@intentset/cli` is
|
|
24
|
+
installed. The command is always `@intentset/cli`'s: this package has no `intentset` binary, and npx asked
|
|
25
|
+
for `intentset` alone would fetch an unrelated unscoped package from the registry.
|
|
26
|
+
|
|
27
|
+
From code, `publish(graph, registries, request, { snapshot, publishedAt })` returns the documents, the index, the help
|
|
28
|
+
file and the diagnostics, and refuses the whole request when any field is missing or undeclared (PUB001).
|
|
29
|
+
`@intentset/help` reads the help file in the product.
|
|
30
|
+
|
|
31
|
+
## Learn more
|
|
32
|
+
|
|
33
|
+
Part of [Intentset](https://intentset.org/), which keeps product intent connected to the code that delivers it and the
|
|
34
|
+
checks that verify it, as readable Markdown files in a repository. The specifications are at
|
|
35
|
+
https://intentset.org/specifications/ and the source at https://github.com/intentset/intentset.
|
|
36
|
+
|
|
37
|
+
## Licence
|
|
38
|
+
|
|
39
|
+
MIT
|
package/dist/generate.d.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*
|
|
5
5
|
* The document is the knowledge body, unchanged, under frontmatter that
|
|
6
6
|
* carries `markset: 0` and a top-level `intentset-publication` block: the
|
|
7
|
-
* generated profile `intentset/publication/0.
|
|
7
|
+
* generated profile `intentset/publication/0.2`, marked derived, with the
|
|
8
8
|
* provenance Core §9 requires. It is a top-level key, not `intentset:`, so
|
|
9
9
|
* nothing reads a generated document as a canonical record. A comment line
|
|
10
10
|
* after the frontmatter says the same to a person opening the file.
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
import type { Artifact, Diagnostic, Graph, Visibility } from "@intentset/core";
|
|
23
23
|
import type { Snapshot } from "./project.ts";
|
|
24
24
|
import { type PublicationRequest } from "./request.ts";
|
|
25
|
-
export declare const PUBLICATION_PROFILE = "intentset/publication/0.
|
|
25
|
+
export declare const PUBLICATION_PROFILE = "intentset/publication/0.2";
|
|
26
26
|
/** The top-level frontmatter key of a generated document. */
|
|
27
27
|
export declare const PUBLICATION_KEY = "intentset-publication";
|
|
28
28
|
export interface SourceStamp {
|
package/dist/generate.js
CHANGED
|
@@ -4,7 +4,7 @@ import { bodyLineOffset } from "./body.js";
|
|
|
4
4
|
import { publicationDiagnostic, sortedUnique } from "./diagnostic.js";
|
|
5
5
|
import { admits } from "./request.js";
|
|
6
6
|
import { emitYaml } from "./yaml.js";
|
|
7
|
-
export const PUBLICATION_PROFILE = "intentset/publication/0.
|
|
7
|
+
export const PUBLICATION_PROFILE = "intentset/publication/0.2";
|
|
8
8
|
/** The top-level frontmatter key of a generated document. */
|
|
9
9
|
export const PUBLICATION_KEY = "intentset-publication";
|
|
10
10
|
/** The line after the frontmatter that marks a generated file. */
|
package/dist/help.d.ts
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
import type { Graph, Visibility } from "@intentset/core";
|
|
15
15
|
import type { Snapshot } from "./project.ts";
|
|
16
16
|
import type { PublicationRequest } from "./request.ts";
|
|
17
|
-
export declare const HELP_PROFILE = "intentset/help/0.
|
|
17
|
+
export declare const HELP_PROFILE = "intentset/help/0.2";
|
|
18
18
|
/** The file's name beside the published documents. */
|
|
19
19
|
export declare const HELP_FILE = "help.json";
|
|
20
20
|
export interface HelpKnowledge {
|
package/dist/help.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { compareStrings } from "./diagnostic.js";
|
|
2
|
-
export const HELP_PROFILE = "intentset/help/0.
|
|
2
|
+
export const HELP_PROFILE = "intentset/help/0.2";
|
|
3
3
|
/** The file's name beside the published documents. */
|
|
4
4
|
export const HELP_FILE = "help.json";
|
|
5
5
|
/** The help file for the documents a run published, which are given by knowledge ID. */
|
package/package.json
CHANGED
|
@@ -1,7 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@intentset/publisher",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.7.0",
|
|
4
4
|
"description": "Audience and release projection of reviewed knowledge into Markset documents with provenance.",
|
|
5
|
+
"keywords": [
|
|
6
|
+
"intentset",
|
|
7
|
+
"publishing",
|
|
8
|
+
"documentation",
|
|
9
|
+
"markset",
|
|
10
|
+
"knowledge-base"
|
|
11
|
+
],
|
|
5
12
|
"license": "MIT",
|
|
6
13
|
"type": "module",
|
|
7
14
|
"engines": {
|
|
@@ -28,8 +35,8 @@
|
|
|
28
35
|
}
|
|
29
36
|
},
|
|
30
37
|
"dependencies": {
|
|
31
|
-
"@intentset/core": "^0.
|
|
32
|
-
"@intentset/markset-adapter": "^0.
|
|
38
|
+
"@intentset/core": "^0.7.0",
|
|
39
|
+
"@intentset/markset-adapter": "^0.7.0",
|
|
33
40
|
"@markset-lang/parser": "0.4.1",
|
|
34
41
|
"@markset-lang/render-html": "0.4.1"
|
|
35
42
|
}
|
package/src/generate.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*
|
|
5
5
|
* The document is the knowledge body, unchanged, under frontmatter that
|
|
6
6
|
* carries `markset: 0` and a top-level `intentset-publication` block: the
|
|
7
|
-
* generated profile `intentset/publication/0.
|
|
7
|
+
* generated profile `intentset/publication/0.2`, marked derived, with the
|
|
8
8
|
* provenance Core §9 requires. It is a top-level key, not `intentset:`, so
|
|
9
9
|
* nothing reads a generated document as a canonical record. A comment line
|
|
10
10
|
* after the frontmatter says the same to a person opening the file.
|
|
@@ -28,7 +28,7 @@ import type { Snapshot } from "./project.ts";
|
|
|
28
28
|
import { type PublicationRequest, admits } from "./request.ts";
|
|
29
29
|
import { type YamlValue, emitYaml } from "./yaml.ts";
|
|
30
30
|
|
|
31
|
-
export const PUBLICATION_PROFILE = "intentset/publication/0.
|
|
31
|
+
export const PUBLICATION_PROFILE = "intentset/publication/0.2";
|
|
32
32
|
/** The top-level frontmatter key of a generated document. */
|
|
33
33
|
export const PUBLICATION_KEY = "intentset-publication";
|
|
34
34
|
|
package/src/help.ts
CHANGED
|
@@ -16,7 +16,7 @@ import { compareStrings } from "./diagnostic.ts";
|
|
|
16
16
|
import type { Snapshot } from "./project.ts";
|
|
17
17
|
import type { PublicationRequest } from "./request.ts";
|
|
18
18
|
|
|
19
|
-
export const HELP_PROFILE = "intentset/help/0.
|
|
19
|
+
export const HELP_PROFILE = "intentset/help/0.2";
|
|
20
20
|
/** The file's name beside the published documents. */
|
|
21
21
|
export const HELP_FILE = "help.json";
|
|
22
22
|
|