@bridge-ds/mcp 0.4.1 → 0.5.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/dist/branches.d.ts +8 -0
- package/dist/{chunk-MXMMPO7F.js → chunk-MHCXMHCL.js} +952 -96
- package/dist/explorations.d.ts +6 -1
- package/dist/index.js +1 -1
- package/dist/lib.d.ts +1 -0
- package/dist/lib.js +3 -1
- package/dist/ops.d.ts +3 -0
- package/dist/pieces.d.ts +122 -0
- package/package.json +3 -3
package/dist/branches.d.ts
CHANGED
|
@@ -9,8 +9,16 @@ export declare const RIGHTS: {
|
|
|
9
9
|
readonly draft: "Pull requests: read and write (you must be the author, as in Studio)";
|
|
10
10
|
readonly docs: "Contents and Pull requests: read and write";
|
|
11
11
|
};
|
|
12
|
+
export declare function reader(ctx: BridgeContext): Promise<GitHubClient>;
|
|
13
|
+
/**
|
|
14
|
+
* A client for writes on a branch someone already opened (any name, never a protected branch): the token is required,
|
|
15
|
+
* with the rights `need` names, so the error says exactly what to add.
|
|
16
|
+
*/
|
|
17
|
+
export declare function writer(ctx: BridgeContext, what: string, need: string): Promise<GitHubClient>;
|
|
12
18
|
/** 12, "#12" or a pull request link: the branch number. Throws how to fix it otherwise. */
|
|
13
19
|
export declare function branchNumber(input: number | string): number;
|
|
20
|
+
/** The viewer of the token, or null without one (or when GitHub does not say). */
|
|
21
|
+
export declare function viewerOf(ctx: BridgeContext, gh: GitHubClient): Promise<string | null>;
|
|
14
22
|
/** Everything Studio reads about one branch to paint its header and decide its actions. */
|
|
15
23
|
export declare function branchFacts(ctx: BridgeContext, gh: GitHubClient, n: number, viewer: string | null): Promise<{
|
|
16
24
|
config: BridgeConfig;
|