reposets 3.1.3 → 3.1.4

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/bin/reposets.js CHANGED
@@ -32,7 +32,7 @@ import { Command } from "effect/cli";
32
32
  * `0.0.0 (dev build)` from every build until the version was threaded down
33
33
  * from here through {@link Invocation}.
34
34
  */
35
- const VERSION = "3.1.3";
35
+ const VERSION = "3.1.4";
36
36
  /**
37
37
  * The application's directories: XDG resolution and the `reposets` namespace
38
38
  * under it.
package/index.d.ts CHANGED
@@ -75,7 +75,7 @@ export declare const ConfigSchema: Schema.Struct<{
75
75
  }>>;
76
76
  }>>;
77
77
  readonly bypass_actors: Schema.optional<Schema.$Array<Schema.Struct<{
78
- readonly actor_id: Schema.optional<Schema.Union<readonly [Schema.Int, Schema.Struct<{
78
+ readonly actor_id: Schema.optional<Schema.Union<readonly [Schema.Natural, Schema.Struct<{
79
79
  readonly resolved: Schema.String;
80
80
  }>]>>;
81
81
  readonly actor_type: Schema.Literals<readonly ["Integration", "OrganizationAdmin", "RepositoryRole", "Team", "DeployKey"]>;
@@ -96,12 +96,12 @@ export declare const ConfigSchema: Schema.Struct<{
96
96
  readonly status_checks: Schema.optional<Schema.Struct<{
97
97
  readonly update_branch: Schema.optional<Schema.Boolean>;
98
98
  readonly on_creation: Schema.optional<Schema.Boolean>;
99
- readonly default_integration_id: Schema.optional<Schema.Union<readonly [Schema.Int, Schema.Struct<{
99
+ readonly default_integration_id: Schema.optional<Schema.Union<readonly [Schema.Natural, Schema.Struct<{
100
100
  readonly resolved: Schema.String;
101
101
  }>]>>;
102
102
  readonly required: Schema.$Array<Schema.Struct<{
103
103
  readonly context: Schema.String;
104
- readonly integration_id: Schema.optional<Schema.Union<readonly [Schema.Int, Schema.Struct<{
104
+ readonly integration_id: Schema.optional<Schema.Union<readonly [Schema.Natural, Schema.Struct<{
105
105
  readonly resolved: Schema.String;
106
106
  }>]>>;
107
107
  }>>;
@@ -136,7 +136,7 @@ export declare const ConfigSchema: Schema.Struct<{
136
136
  readonly file_patterns: Schema.$Array<Schema.String>;
137
137
  readonly minimum_approvals: Schema.Int;
138
138
  readonly reviewer: Schema.Struct<{
139
- readonly id: Schema.Int;
139
+ readonly id: Schema.Natural;
140
140
  readonly type: Schema.Literal<"Team">;
141
141
  }>;
142
142
  }>>>;
@@ -164,7 +164,7 @@ export declare const ConfigSchema: Schema.Struct<{
164
164
  readonly required: Schema.$Array<Schema.Struct<{
165
165
  readonly path: Schema.String;
166
166
  readonly ref: Schema.optional<Schema.String>;
167
- readonly repository_id: Schema.Union<readonly [Schema.Int, Schema.Struct<{
167
+ readonly repository_id: Schema.Union<readonly [Schema.Natural, Schema.Struct<{
168
168
  readonly resolved: Schema.String;
169
169
  }>]>;
170
170
  readonly sha: Schema.optional<Schema.String>;
@@ -186,7 +186,7 @@ export declare const ConfigSchema: Schema.Struct<{
186
186
  }>>;
187
187
  }>>;
188
188
  readonly bypass_actors: Schema.optional<Schema.$Array<Schema.Struct<{
189
- readonly actor_id: Schema.optional<Schema.Union<readonly [Schema.Int, Schema.Struct<{
189
+ readonly actor_id: Schema.optional<Schema.Union<readonly [Schema.Natural, Schema.Struct<{
190
190
  readonly resolved: Schema.String;
191
191
  }>]>>;
192
192
  readonly actor_type: Schema.Literals<readonly ["Integration", "OrganizationAdmin", "RepositoryRole", "Team", "DeployKey"]>;
@@ -207,12 +207,12 @@ export declare const ConfigSchema: Schema.Struct<{
207
207
  readonly status_checks: Schema.optional<Schema.Struct<{
208
208
  readonly update_branch: Schema.optional<Schema.Boolean>;
209
209
  readonly on_creation: Schema.optional<Schema.Boolean>;
210
- readonly default_integration_id: Schema.optional<Schema.Union<readonly [Schema.Int, Schema.Struct<{
210
+ readonly default_integration_id: Schema.optional<Schema.Union<readonly [Schema.Natural, Schema.Struct<{
211
211
  readonly resolved: Schema.String;
212
212
  }>]>>;
213
213
  readonly required: Schema.$Array<Schema.Struct<{
214
214
  readonly context: Schema.String;
215
- readonly integration_id: Schema.optional<Schema.Union<readonly [Schema.Int, Schema.Struct<{
215
+ readonly integration_id: Schema.optional<Schema.Union<readonly [Schema.Natural, Schema.Struct<{
216
216
  readonly resolved: Schema.String;
217
217
  }>]>>;
218
218
  }>>;
@@ -248,7 +248,7 @@ export declare const ConfigSchema: Schema.Struct<{
248
248
  readonly prevent_self_review: Schema.optional<Schema.Boolean>;
249
249
  readonly reviewers: Schema.optional<Schema.$Array<Schema.Struct<{
250
250
  readonly type: Schema.Literals<readonly ["User", "Team"]>;
251
- readonly id: Schema.Int;
251
+ readonly id: Schema.Natural;
252
252
  }>>>;
253
253
  readonly deployment_branches: Schema.optional<Schema.Union<readonly [Schema.Literals<readonly ["all", "protected"]>, Schema.$Array<Schema.Struct<{
254
254
  readonly name: Schema.String;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "reposets",
3
- "version": "3.1.3",
3
+ "version": "3.1.4",
4
4
  "private": false,
5
5
  "description": "CLI tool to sync GitHub repo settings, secrets and rulesets across personal repositories",
6
6
  "keywords": [
@@ -48,20 +48,20 @@
48
48
  },
49
49
  "dependencies": {
50
50
  "@1password/sdk": "^0.5.0",
51
- "@effect/platform-node": "^4.0.2",
52
- "@effected/app": "^0.21.2",
53
- "@effected/cli": "^0.16.1",
54
- "@effected/config-file": "^0.14.2",
55
- "@effected/env": "^0.1.1",
56
- "@effected/github": "^0.17.0",
57
- "@effected/glob": "^0.10.0",
58
- "@effected/schemastore": "^0.21.4",
59
- "@effected/store": "^0.13.1",
60
- "@effected/toml": "^0.11.1",
61
- "@effected/walker": "^0.15.0",
62
- "@effected/xdg": "^0.9.0",
51
+ "@effect/platform-node": "^4.0.4",
52
+ "@effected/app": "^0.23.0",
53
+ "@effected/cli": "^0.18.0",
54
+ "@effected/config-file": "^0.16.0",
55
+ "@effected/env": "^0.3.0",
56
+ "@effected/github": "^0.20.0",
57
+ "@effected/glob": "^0.12.0",
58
+ "@effected/schemastore": "^0.23.0",
59
+ "@effected/store": "^0.15.0",
60
+ "@effected/toml": "^0.13.0",
61
+ "@effected/walker": "^0.17.0",
62
+ "@effected/xdg": "^0.11.0",
63
63
  "blakejs": "^1.2.1",
64
- "effect": "^4.0.2",
64
+ "effect": "^4.0.4",
65
65
  "ink": "^8.0.0",
66
66
  "react": "^19.3.0"
67
67
  },
@@ -8,7 +8,7 @@ const ReviewerTypeSchema = Schema.Literals(["User", "Team"]).annotate({
8
8
  });
9
9
  const ReviewerSchema = Schema.Struct({
10
10
  type: ReviewerTypeSchema,
11
- id: Schema.Int.annotate({
11
+ id: Schema.Natural.annotate({
12
12
  title: "Reviewer ID",
13
13
  description: "The numeric GitHub ID of the user or team"
14
14
  })
@@ -39,7 +39,7 @@ const BypassModeSchema = Schema.Literals([
39
39
  * @public
40
40
  */
41
41
  const BypassActorSchema = Schema.Struct({
42
- actor_id: Schema.optional(Schema.Union([Schema.Int, ResolvedRefSchema]).annotate({
42
+ actor_id: Schema.optional(Schema.Union([Schema.Natural, ResolvedRefSchema]).annotate({
43
43
  title: "Actor ID",
44
44
  description: "The ID of the actor, or a { resolved } reference to a credential label."
45
45
  })),
@@ -85,12 +85,15 @@ const RequiredReviewerSchema = Schema.Struct({
85
85
  title: "File patterns",
86
86
  description: "File patterns this reviewer must approve (fnmatch syntax)"
87
87
  }),
88
- minimum_approvals: Schema.Int.annotate({
88
+ minimum_approvals: Schema.Int.check(Schema.isBetween({
89
+ minimum: 0,
90
+ maximum: 10
91
+ })).annotate({
89
92
  title: "Minimum approvals",
90
- description: "Minimum approvals required from this team (0 = optional)"
93
+ description: "Minimum approvals required from this team (0-10, 0 = optional)"
91
94
  }),
92
95
  reviewer: Schema.Struct({
93
- id: Schema.Int.annotate({
96
+ id: Schema.Natural.annotate({
94
97
  title: "Team ID",
95
98
  description: "Team ID"
96
99
  }),
@@ -102,7 +105,7 @@ const StatusCheckSchema = Schema.Struct({
102
105
  title: "Context",
103
106
  description: "The status check context name that must be present on the commit"
104
107
  }),
105
- integration_id: Schema.optional(Schema.Union([Schema.Int, ResolvedRefSchema]).annotate({
108
+ integration_id: Schema.optional(Schema.Union([Schema.Natural, ResolvedRefSchema]).annotate({
106
109
  title: "Integration ID",
107
110
  description: "The integration ID, or a { resolved } reference to a credential label"
108
111
  }))
@@ -116,7 +119,7 @@ const WorkflowFileSchema = Schema.Struct({
116
119
  title: "Ref",
117
120
  description: "Branch or tag of the workflow file"
118
121
  })),
119
- repository_id: Schema.Union([Schema.Int, ResolvedRefSchema]).annotate({
122
+ repository_id: Schema.Union([Schema.Natural, ResolvedRefSchema]).annotate({
120
123
  title: "Repository ID",
121
124
  description: "Repository ID, or a { resolved } reference to a credential label"
122
125
  }),
@@ -197,7 +200,7 @@ const StatusChecksShorthandSchema = Schema.Struct({
197
200
  title: "Enforce on create",
198
201
  description: "When false, allows branch creation even if checks would prohibit it"
199
202
  })),
200
- default_integration_id: Schema.optional(Schema.Union([Schema.Int, ResolvedRefSchema]).annotate({
203
+ default_integration_id: Schema.optional(Schema.Union([Schema.Natural, ResolvedRefSchema]).annotate({
201
204
  title: "Default integration ID",
202
205
  description: "Default integration ID applied to all checks that do not specify one"
203
206
  })),
@@ -19,7 +19,7 @@ var SyncJournal = class extends Context.Service()("reposets/SyncJournal", { make
19
19
  const sql = store.client;
20
20
  return {
21
21
  startRun: (options) => Effect.gen(function* () {
22
- const id = yield* crypto.randomUUIDv7;
22
+ const id = yield* crypto.randomUUIDv7();
23
23
  const startedAt = yield* DateTime.now;
24
24
  yield* sql`
25
25
  INSERT INTO sync_run (id, started_at, group_name, dry_run)