@quonfig/cli 0.0.72 → 0.0.73
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 +97 -73
- package/dist/commands/cleanup/status.js +5 -1
- package/dist/commands/config-schema.js +8 -3
- package/dist/commands/info.js +9 -15
- package/dist/commands/log-level.js +7 -10
- package/dist/commands/set-default.d.ts +1 -0
- package/dist/commands/set-default.js +106 -71
- package/dist/commands/set-rollout.d.ts +1 -0
- package/dist/commands/set-rollout.js +65 -18
- package/dist/index.d.ts +30 -0
- package/dist/index.js +105 -8
- package/dist/init/templates.js +43 -0
- package/dist/util/rules.d.ts +98 -0
- package/dist/util/rules.js +131 -0
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/oclif.manifest.json +18 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -17,7 +17,7 @@ $ npm install -g @quonfig/cli
|
|
|
17
17
|
$ qfg COMMAND
|
|
18
18
|
running command...
|
|
19
19
|
$ qfg (--version)
|
|
20
|
-
@quonfig/cli/0.0.
|
|
20
|
+
@quonfig/cli/0.0.73 linux-x64 node-v24.4.1
|
|
21
21
|
$ qfg --help [COMMAND]
|
|
22
22
|
USAGE
|
|
23
23
|
$ qfg COMMAND
|
|
@@ -201,7 +201,7 @@ EXAMPLES
|
|
|
201
201
|
$ qfg activity restore my.flag --yes
|
|
202
202
|
```
|
|
203
203
|
|
|
204
|
-
_See code: [src/commands/activity.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
204
|
+
_See code: [src/commands/activity.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/activity.ts)_
|
|
205
205
|
|
|
206
206
|
## `qfg activity deleted`
|
|
207
207
|
|
|
@@ -230,7 +230,7 @@ EXAMPLES
|
|
|
230
230
|
$ qfg activity deleted --json
|
|
231
231
|
```
|
|
232
232
|
|
|
233
|
-
_See code: [src/commands/activity/deleted.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
233
|
+
_See code: [src/commands/activity/deleted.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/activity/deleted.ts)_
|
|
234
234
|
|
|
235
235
|
## `qfg activity feed`
|
|
236
236
|
|
|
@@ -265,7 +265,7 @@ EXAMPLES
|
|
|
265
265
|
$ qfg activity feed --json
|
|
266
266
|
```
|
|
267
267
|
|
|
268
|
-
_See code: [src/commands/activity/feed.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
268
|
+
_See code: [src/commands/activity/feed.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/activity/feed.ts)_
|
|
269
269
|
|
|
270
270
|
## `qfg activity history [NAME]`
|
|
271
271
|
|
|
@@ -299,7 +299,7 @@ EXAMPLES
|
|
|
299
299
|
$ qfg activity history request.timeout --json
|
|
300
300
|
```
|
|
301
301
|
|
|
302
|
-
_See code: [src/commands/activity/history.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
302
|
+
_See code: [src/commands/activity/history.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/activity/history.ts)_
|
|
303
303
|
|
|
304
304
|
## `qfg activity restore [NAME]`
|
|
305
305
|
|
|
@@ -338,7 +338,7 @@ EXAMPLES
|
|
|
338
338
|
$ qfg activity restore request.timeout --type config --yes
|
|
339
339
|
```
|
|
340
340
|
|
|
341
|
-
_See code: [src/commands/activity/restore.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
341
|
+
_See code: [src/commands/activity/restore.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/activity/restore.ts)_
|
|
342
342
|
|
|
343
343
|
## `qfg audit-log [NAME]`
|
|
344
344
|
|
|
@@ -366,7 +366,7 @@ EXAMPLES
|
|
|
366
366
|
$ qfg audit-log my.flag
|
|
367
367
|
```
|
|
368
368
|
|
|
369
|
-
_See code: [src/commands/audit-log.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
369
|
+
_See code: [src/commands/audit-log.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/audit-log.ts)_
|
|
370
370
|
|
|
371
371
|
## `qfg cleanup`
|
|
372
372
|
|
|
@@ -407,7 +407,7 @@ EXAMPLES
|
|
|
407
407
|
$ qfg cleanup status my.flag.key
|
|
408
408
|
```
|
|
409
409
|
|
|
410
|
-
_See code: [src/commands/cleanup.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
410
|
+
_See code: [src/commands/cleanup.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/cleanup.ts)_
|
|
411
411
|
|
|
412
412
|
## `qfg cleanup list`
|
|
413
413
|
|
|
@@ -453,7 +453,7 @@ EXAMPLES
|
|
|
453
453
|
$ qfg cleanup list --json
|
|
454
454
|
```
|
|
455
455
|
|
|
456
|
-
_See code: [src/commands/cleanup/list.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
456
|
+
_See code: [src/commands/cleanup/list.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/cleanup/list.ts)_
|
|
457
457
|
|
|
458
458
|
## `qfg cleanup remove [NAME]`
|
|
459
459
|
|
|
@@ -498,7 +498,7 @@ EXAMPLES
|
|
|
498
498
|
$ qfg cleanup remove my.flag.key --json
|
|
499
499
|
```
|
|
500
500
|
|
|
501
|
-
_See code: [src/commands/cleanup/remove.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
501
|
+
_See code: [src/commands/cleanup/remove.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/cleanup/remove.ts)_
|
|
502
502
|
|
|
503
503
|
## `qfg cleanup status [NAME]`
|
|
504
504
|
|
|
@@ -538,7 +538,7 @@ EXAMPLES
|
|
|
538
538
|
$ qfg cleanup status my.flag.key --json
|
|
539
539
|
```
|
|
540
540
|
|
|
541
|
-
_See code: [src/commands/cleanup/status.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
541
|
+
_See code: [src/commands/cleanup/status.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/cleanup/status.ts)_
|
|
542
542
|
|
|
543
543
|
## `qfg cleanup verify [NAME]`
|
|
544
544
|
|
|
@@ -584,7 +584,7 @@ EXAMPLES
|
|
|
584
584
|
$ qfg cleanup verify my.flag.key && qfg delete my.flag.key
|
|
585
585
|
```
|
|
586
586
|
|
|
587
|
-
_See code: [src/commands/cleanup/verify.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
587
|
+
_See code: [src/commands/cleanup/verify.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/cleanup/verify.ts)_
|
|
588
588
|
|
|
589
589
|
## `qfg config-schema`
|
|
590
590
|
|
|
@@ -613,7 +613,7 @@ EXAMPLES
|
|
|
613
613
|
$ qfg config-schema --json-schema # full JSON Schema document (copy into your editor)
|
|
614
614
|
```
|
|
615
615
|
|
|
616
|
-
_See code: [src/commands/config-schema.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
616
|
+
_See code: [src/commands/config-schema.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/config-schema.ts)_
|
|
617
617
|
|
|
618
618
|
## `qfg create NAME`
|
|
619
619
|
|
|
@@ -700,7 +700,7 @@ EXAMPLES
|
|
|
700
700
|
$ qfg set-rollout my.new.flag --environment production --true-percent 20
|
|
701
701
|
```
|
|
702
702
|
|
|
703
|
-
_See code: [src/commands/create.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
703
|
+
_See code: [src/commands/create.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/create.ts)_
|
|
704
704
|
|
|
705
705
|
## `qfg delete NAME`
|
|
706
706
|
|
|
@@ -746,7 +746,7 @@ EXAMPLES
|
|
|
746
746
|
$ qfg delete my.config --yes
|
|
747
747
|
```
|
|
748
748
|
|
|
749
|
-
_See code: [src/commands/delete.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
749
|
+
_See code: [src/commands/delete.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/delete.ts)_
|
|
750
750
|
|
|
751
751
|
## `qfg flag info [NAME]`
|
|
752
752
|
|
|
@@ -950,7 +950,7 @@ EXAMPLES
|
|
|
950
950
|
$ qfg generate --targets node-ts -o ./dist # combine with targets
|
|
951
951
|
```
|
|
952
952
|
|
|
953
|
-
_See code: [src/commands/generate.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
953
|
+
_See code: [src/commands/generate.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/generate.ts)_
|
|
954
954
|
|
|
955
955
|
## `qfg generate-new-hex-key`
|
|
956
956
|
|
|
@@ -973,7 +973,7 @@ EXAMPLES
|
|
|
973
973
|
$ qfg generate-new-hex-key
|
|
974
974
|
```
|
|
975
975
|
|
|
976
|
-
_See code: [src/commands/generate-new-hex-key.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
976
|
+
_See code: [src/commands/generate-new-hex-key.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/generate-new-hex-key.ts)_
|
|
977
977
|
|
|
978
978
|
## `qfg get [NAME]`
|
|
979
979
|
|
|
@@ -1005,7 +1005,7 @@ EXAMPLES
|
|
|
1005
1005
|
$ qfg get my.config.name --environment=production
|
|
1006
1006
|
```
|
|
1007
1007
|
|
|
1008
|
-
_See code: [src/commands/get.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1008
|
+
_See code: [src/commands/get.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/get.ts)_
|
|
1009
1009
|
|
|
1010
1010
|
## `qfg history NAME`
|
|
1011
1011
|
|
|
@@ -1031,7 +1031,7 @@ EXAMPLES
|
|
|
1031
1031
|
$ qfg history my.flag
|
|
1032
1032
|
```
|
|
1033
1033
|
|
|
1034
|
-
_See code: [src/commands/history.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1034
|
+
_See code: [src/commands/history.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/history.ts)_
|
|
1035
1035
|
|
|
1036
1036
|
## `qfg info [NAME]`
|
|
1037
1037
|
|
|
@@ -1079,7 +1079,7 @@ EXAMPLES
|
|
|
1079
1079
|
$ qfg info my.config.name --exclude-evaluations # skip 24h stats
|
|
1080
1080
|
```
|
|
1081
1081
|
|
|
1082
|
-
_See code: [src/commands/info.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1082
|
+
_See code: [src/commands/info.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/info.ts)_
|
|
1083
1083
|
|
|
1084
1084
|
## `qfg init [DIRECTORY]`
|
|
1085
1085
|
|
|
@@ -1119,7 +1119,7 @@ EXAMPLES
|
|
|
1119
1119
|
$ qfg init --dry-run
|
|
1120
1120
|
```
|
|
1121
1121
|
|
|
1122
|
-
_See code: [src/commands/init.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1122
|
+
_See code: [src/commands/init.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/init.ts)_
|
|
1123
1123
|
|
|
1124
1124
|
## `qfg interactive`
|
|
1125
1125
|
|
|
@@ -1149,7 +1149,7 @@ EXAMPLES
|
|
|
1149
1149
|
$ qfg
|
|
1150
1150
|
```
|
|
1151
1151
|
|
|
1152
|
-
_See code: [src/commands/interactive.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1152
|
+
_See code: [src/commands/interactive.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/interactive.ts)_
|
|
1153
1153
|
|
|
1154
1154
|
## `qfg list`
|
|
1155
1155
|
|
|
@@ -1189,7 +1189,7 @@ EXAMPLES
|
|
|
1189
1189
|
$ qfg list --feature-flags
|
|
1190
1190
|
```
|
|
1191
1191
|
|
|
1192
|
-
_See code: [src/commands/list.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1192
|
+
_See code: [src/commands/list.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/list.ts)_
|
|
1193
1193
|
|
|
1194
1194
|
## `qfg log`
|
|
1195
1195
|
|
|
@@ -1214,7 +1214,7 @@ EXAMPLES
|
|
|
1214
1214
|
$ qfg log --limit 5
|
|
1215
1215
|
```
|
|
1216
1216
|
|
|
1217
|
-
_See code: [src/commands/log.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1217
|
+
_See code: [src/commands/log.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/log.ts)_
|
|
1218
1218
|
|
|
1219
1219
|
## `qfg log-level NAME`
|
|
1220
1220
|
|
|
@@ -1279,7 +1279,7 @@ EXAMPLES
|
|
|
1279
1279
|
$ qfg log-level log-level.my-app --target=Chatty --value=INFO --environment=production
|
|
1280
1280
|
```
|
|
1281
1281
|
|
|
1282
|
-
_See code: [src/commands/log-level.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1282
|
+
_See code: [src/commands/log-level.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/log-level.ts)_
|
|
1283
1283
|
|
|
1284
1284
|
## `qfg login`
|
|
1285
1285
|
|
|
@@ -1304,7 +1304,7 @@ EXAMPLES
|
|
|
1304
1304
|
$ qfg login --profile myprofile
|
|
1305
1305
|
```
|
|
1306
1306
|
|
|
1307
|
-
_See code: [src/commands/login.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1307
|
+
_See code: [src/commands/login.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/login.ts)_
|
|
1308
1308
|
|
|
1309
1309
|
## `qfg logout`
|
|
1310
1310
|
|
|
@@ -1327,7 +1327,7 @@ EXAMPLES
|
|
|
1327
1327
|
$ qfg logout
|
|
1328
1328
|
```
|
|
1329
1329
|
|
|
1330
|
-
_See code: [src/commands/logout.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1330
|
+
_See code: [src/commands/logout.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/logout.ts)_
|
|
1331
1331
|
|
|
1332
1332
|
## `qfg migrate`
|
|
1333
1333
|
|
|
@@ -1392,7 +1392,7 @@ EXAMPLES
|
|
|
1392
1392
|
$ qfg migrate --from launch --source-api-key $LAUNCH_API_KEY --dir ./quonfig-repo --staging
|
|
1393
1393
|
```
|
|
1394
1394
|
|
|
1395
|
-
_See code: [src/commands/migrate.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1395
|
+
_See code: [src/commands/migrate.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/migrate.ts)_
|
|
1396
1396
|
|
|
1397
1397
|
## `qfg migrate doctor`
|
|
1398
1398
|
|
|
@@ -1430,7 +1430,7 @@ EXAMPLES
|
|
|
1430
1430
|
$ qfg migrate doctor --json
|
|
1431
1431
|
```
|
|
1432
1432
|
|
|
1433
|
-
_See code: [src/commands/migrate/doctor.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1433
|
+
_See code: [src/commands/migrate/doctor.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/migrate/doctor.ts)_
|
|
1434
1434
|
|
|
1435
1435
|
## `qfg migrate my-code`
|
|
1436
1436
|
|
|
@@ -1462,7 +1462,7 @@ EXAMPLES
|
|
|
1462
1462
|
$ qfg migrate my-code --dry-run
|
|
1463
1463
|
```
|
|
1464
1464
|
|
|
1465
|
-
_See code: [src/commands/migrate/my-code.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1465
|
+
_See code: [src/commands/migrate/my-code.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/migrate/my-code.ts)_
|
|
1466
1466
|
|
|
1467
1467
|
## `qfg migrate status`
|
|
1468
1468
|
|
|
@@ -1493,7 +1493,7 @@ EXAMPLES
|
|
|
1493
1493
|
$ qfg migrate status --json
|
|
1494
1494
|
```
|
|
1495
1495
|
|
|
1496
|
-
_See code: [src/commands/migrate/status.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1496
|
+
_See code: [src/commands/migrate/status.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/migrate/status.ts)_
|
|
1497
1497
|
|
|
1498
1498
|
## `qfg override [NAME] [VALUE]`
|
|
1499
1499
|
|
|
@@ -1548,7 +1548,7 @@ EXAMPLES
|
|
|
1548
1548
|
$ qfg override my.flag true --env=staging
|
|
1549
1549
|
```
|
|
1550
1550
|
|
|
1551
|
-
_See code: [src/commands/override.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1551
|
+
_See code: [src/commands/override.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/override.ts)_
|
|
1552
1552
|
|
|
1553
1553
|
## `qfg pull`
|
|
1554
1554
|
|
|
@@ -1595,7 +1595,7 @@ EXAMPLES
|
|
|
1595
1595
|
$ qfg pull # uses QUONFIG_DIR env var
|
|
1596
1596
|
```
|
|
1597
1597
|
|
|
1598
|
-
_See code: [src/commands/pull.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1598
|
+
_See code: [src/commands/pull.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/pull.ts)_
|
|
1599
1599
|
|
|
1600
1600
|
## `qfg push`
|
|
1601
1601
|
|
|
@@ -1644,7 +1644,7 @@ EXAMPLES
|
|
|
1644
1644
|
$ qfg push --dir ./our-config --yes
|
|
1645
1645
|
```
|
|
1646
1646
|
|
|
1647
|
-
_See code: [src/commands/push.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1647
|
+
_See code: [src/commands/push.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/push.ts)_
|
|
1648
1648
|
|
|
1649
1649
|
## `qfg run [COMMAND]`
|
|
1650
1650
|
|
|
@@ -1695,7 +1695,7 @@ EXAMPLES
|
|
|
1695
1695
|
$ qfg run --env DATABASE_URL=db.url --preserve-env --environment=staging -- npm test
|
|
1696
1696
|
```
|
|
1697
1697
|
|
|
1698
|
-
_See code: [src/commands/run.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1698
|
+
_See code: [src/commands/run.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/run.ts)_
|
|
1699
1699
|
|
|
1700
1700
|
## `qfg schema NAME`
|
|
1701
1701
|
|
|
@@ -1733,7 +1733,7 @@ EXAMPLES
|
|
|
1733
1733
|
$ qfg schema my-schema --set-json-schema=@schemas/my-schema.json --protected
|
|
1734
1734
|
```
|
|
1735
1735
|
|
|
1736
|
-
_See code: [src/commands/schema.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1736
|
+
_See code: [src/commands/schema.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/schema.ts)_
|
|
1737
1737
|
|
|
1738
1738
|
## `qfg sdk-key`
|
|
1739
1739
|
|
|
@@ -1760,7 +1760,7 @@ EXAMPLES
|
|
|
1760
1760
|
$ qfg sdk-key revoke <key-id>
|
|
1761
1761
|
```
|
|
1762
1762
|
|
|
1763
|
-
_See code: [src/commands/sdk-key.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1763
|
+
_See code: [src/commands/sdk-key.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/sdk-key.ts)_
|
|
1764
1764
|
|
|
1765
1765
|
## `qfg sdk-key create`
|
|
1766
1766
|
|
|
@@ -1792,7 +1792,7 @@ EXAMPLES
|
|
|
1792
1792
|
$ qfg sdk-key create --environment staging --type browser
|
|
1793
1793
|
```
|
|
1794
1794
|
|
|
1795
|
-
_See code: [src/commands/sdk-key/create.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1795
|
+
_See code: [src/commands/sdk-key/create.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/sdk-key/create.ts)_
|
|
1796
1796
|
|
|
1797
1797
|
## `qfg sdk-key list`
|
|
1798
1798
|
|
|
@@ -1821,7 +1821,7 @@ EXAMPLES
|
|
|
1821
1821
|
$ qfg sdk-key list --environment production
|
|
1822
1822
|
```
|
|
1823
1823
|
|
|
1824
|
-
_See code: [src/commands/sdk-key/list.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1824
|
+
_See code: [src/commands/sdk-key/list.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/sdk-key/list.ts)_
|
|
1825
1825
|
|
|
1826
1826
|
## `qfg sdk-key revoke KEYID`
|
|
1827
1827
|
|
|
@@ -1848,7 +1848,7 @@ EXAMPLES
|
|
|
1848
1848
|
$ qfg sdk-key revoke a1b2c3d4-e5f6-7890-abcd-ef1234567890
|
|
1849
1849
|
```
|
|
1850
1850
|
|
|
1851
|
-
_See code: [src/commands/sdk-key/revoke.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1851
|
+
_See code: [src/commands/sdk-key/revoke.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/sdk-key/revoke.ts)_
|
|
1852
1852
|
|
|
1853
1853
|
## `qfg serve`
|
|
1854
1854
|
|
|
@@ -1905,16 +1905,17 @@ EXAMPLES
|
|
|
1905
1905
|
$ qfg serve --port 6581 --frontend-sdk-key PUBLIC_KEY
|
|
1906
1906
|
```
|
|
1907
1907
|
|
|
1908
|
-
_See code: [src/commands/serve.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1908
|
+
_See code: [src/commands/serve.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/serve.ts)_
|
|
1909
1909
|
|
|
1910
1910
|
## `qfg set-default [NAME]`
|
|
1911
1911
|
|
|
1912
|
-
Set the
|
|
1912
|
+
Set the fallback value for a flag or config in one environment.
|
|
1913
1913
|
|
|
1914
1914
|
```
|
|
1915
1915
|
USAGE
|
|
1916
1916
|
$ qfg set-default [NAME] [--json] [--interactive] [--no-color] [--verbose] [-w <value>] [--confidential]
|
|
1917
|
-
[--env-var <value>] [--environment <value>] [--value <value>] [--confirm] [--secret]
|
|
1917
|
+
[--env-var <value>] [--environment <value>] [--replace-targeting] [--value <value>] [--confirm] [--secret]
|
|
1918
|
+
[--secret-key-name <value>]
|
|
1918
1919
|
|
|
1919
1920
|
ARGUMENTS
|
|
1920
1921
|
NAME config/feature-flag/etc. name
|
|
@@ -1924,6 +1925,8 @@ FLAGS
|
|
|
1924
1925
|
--confirm confirm without prompt
|
|
1925
1926
|
--env-var=<value> environment variable to use as default value
|
|
1926
1927
|
--environment=<value> environment to change
|
|
1928
|
+
--replace-targeting set the value for EVERYONE: delete this environment's targeting rules instead of keeping
|
|
1929
|
+
them (they stay in git history)
|
|
1927
1930
|
--secret encrypt the value of this item
|
|
1928
1931
|
--secret-key-name=<value> [default: quonfig.secrets.encryption.key] name of the secret key to use for
|
|
1929
1932
|
encryption/decryption
|
|
@@ -1937,15 +1940,17 @@ GLOBAL FLAGS
|
|
|
1937
1940
|
--verbose Verbose output
|
|
1938
1941
|
|
|
1939
1942
|
DESCRIPTION
|
|
1940
|
-
Set the
|
|
1943
|
+
Set the fallback value for a flag or config in one environment.
|
|
1941
1944
|
|
|
1942
|
-
|
|
1943
|
-
|
|
1944
|
-
|
|
1945
|
+
The fallback is the unconditional rule at the end of the environment's rule
|
|
1946
|
+
list: what users receive when no targeting rule matches. Targeting rules and
|
|
1947
|
+
percentage rollouts above it are kept, and the command tells you how many.
|
|
1948
|
+
If the environment has no rules of its own yet, they are copied from the
|
|
1949
|
+
flag's default rules first, so inherited targeting is kept too.
|
|
1945
1950
|
|
|
1946
|
-
|
|
1947
|
-
|
|
1948
|
-
|
|
1951
|
+
To turn a flag on or off for EVERYONE, including users matched by targeting
|
|
1952
|
+
rules, add --replace-targeting. This deletes the environment's targeting
|
|
1953
|
+
rules (they stay in git history).
|
|
1949
1954
|
|
|
1950
1955
|
To set a percentage rollout (gradual rollout / A/B test / canary deploy) instead:
|
|
1951
1956
|
qfg set-rollout my.flag --environment production --true-percent 20
|
|
@@ -1961,7 +1966,7 @@ EXAMPLES
|
|
|
1961
1966
|
|
|
1962
1967
|
$ qfg set-default my.flag.name --value=true --environment=staging
|
|
1963
1968
|
|
|
1964
|
-
$ qfg set-default my.flag.name --value=false --environment=production # kill-switch:
|
|
1969
|
+
$ qfg set-default my.flag.name --value=false --environment=production --replace-targeting # kill-switch: off for everyone
|
|
1965
1970
|
|
|
1966
1971
|
$ qfg set-default my.flag.name --value=true --secret
|
|
1967
1972
|
|
|
@@ -1976,7 +1981,7 @@ EXAMPLES
|
|
|
1976
1981
|
$ qfg pull && qfg config-schema
|
|
1977
1982
|
```
|
|
1978
1983
|
|
|
1979
|
-
_See code: [src/commands/set-default.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
1984
|
+
_See code: [src/commands/set-default.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/set-default.ts)_
|
|
1980
1985
|
|
|
1981
1986
|
## `qfg set-rollout [NAME]`
|
|
1982
1987
|
|
|
@@ -1985,7 +1990,7 @@ Configure a percentage rollout (gradual rollout / A/B test / canary deploy) for
|
|
|
1985
1990
|
```
|
|
1986
1991
|
USAGE
|
|
1987
1992
|
$ qfg set-rollout [NAME] [--json] [--interactive] [--no-color] [--verbose] [-w <value>] [--environment <value>]
|
|
1988
|
-
[--hash-by <value>] [--true-percent <value>] [--weights <value>] [--confirm]
|
|
1993
|
+
[--hash-by <value>] [--true-percent <value>] [--replace-targeting] [--weights <value>] [--confirm]
|
|
1989
1994
|
|
|
1990
1995
|
ARGUMENTS
|
|
1991
1996
|
NAME config/feature-flag/etc. name
|
|
@@ -1994,6 +1999,8 @@ FLAGS
|
|
|
1994
1999
|
--confirm skip the interactive confirmation prompt (useful for scripts and agents)
|
|
1995
2000
|
--environment=<value> environment to update (e.g. production, staging)
|
|
1996
2001
|
--hash-by=<value> [default: user.key] user property used to assign buckets (default: user.key)
|
|
2002
|
+
--replace-targeting roll out to EVERYONE: delete this environment's targeting rules instead of keeping them (they
|
|
2003
|
+
stay in git history)
|
|
1997
2004
|
--true-percent=<value> percentage of users that receive true (0–100). Remaining users receive false. Boolean flags
|
|
1998
2005
|
only.
|
|
1999
2006
|
--weights=<value> comma-separated "value:percent" pairs that must sum to 100 (e.g. "true:20,false:80" or
|
|
@@ -2026,6 +2033,16 @@ DESCRIPTION
|
|
|
2026
2033
|
Use --hash-by to change which property drives the bucket assignment:
|
|
2027
2034
|
qfg set-rollout my.flag --environment production --true-percent 10 --hash-by user.id
|
|
2028
2035
|
|
|
2036
|
+
The rollout becomes the environment's fallback: the unconditional rule at the end
|
|
2037
|
+
of its rule list, what users receive when no targeting rule matches. Targeting
|
|
2038
|
+
rules above it are kept, and the command tells you how many. If the environment
|
|
2039
|
+
has no rules of its own yet, they are copied from the flag's default rules first,
|
|
2040
|
+
so inherited targeting is kept too.
|
|
2041
|
+
|
|
2042
|
+
To roll out to EVERYONE, including users matched by targeting rules, add
|
|
2043
|
+
--replace-targeting. This deletes the environment's targeting rules (they stay in
|
|
2044
|
+
git history).
|
|
2045
|
+
|
|
2029
2046
|
For scripted / agent use, add --confirm to skip the interactive confirmation prompt.
|
|
2030
2047
|
|
|
2031
2048
|
To combine a rollout with segment targeting (e.g. beta ON, holdout OFF, everyone else 50/50),
|
|
@@ -2034,7 +2051,7 @@ DESCRIPTION
|
|
|
2034
2051
|
qfg pull --dir ./config # clone workspace to edit
|
|
2035
2052
|
|
|
2036
2053
|
To revert to a single value for everyone, use:
|
|
2037
|
-
qfg set-default my.flag --environment production --value false
|
|
2054
|
+
qfg set-default my.flag --environment production --value false --replace-targeting
|
|
2038
2055
|
|
|
2039
2056
|
To inspect the current rollout:
|
|
2040
2057
|
qfg info my.flag
|
|
@@ -2046,14 +2063,16 @@ EXAMPLES
|
|
|
2046
2063
|
|
|
2047
2064
|
$ qfg set-rollout my.feature.flag --environment production --true-percent 100 # full rollout
|
|
2048
2065
|
|
|
2049
|
-
|
|
2066
|
+
# For a kill switch — false for EVERYONE, including targeted users — use set-default:
|
|
2067
|
+
|
|
2068
|
+
$ qfg set-default my.feature.flag --value=false --environment=production --replace-targeting
|
|
2050
2069
|
|
|
2051
2070
|
$ qfg set-rollout my.variant.flag --environment production --weights "control:50,treatment:50"
|
|
2052
2071
|
|
|
2053
2072
|
$ qfg set-rollout my.variant.flag --environment production --weights "a:33,b:33,c:34" --hash-by user.id
|
|
2054
2073
|
```
|
|
2055
2074
|
|
|
2056
|
-
_See code: [src/commands/set-rollout.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
2075
|
+
_See code: [src/commands/set-rollout.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/set-rollout.ts)_
|
|
2057
2076
|
|
|
2058
2077
|
## `qfg sync`
|
|
2059
2078
|
|
|
@@ -2085,16 +2104,17 @@ EXAMPLES
|
|
|
2085
2104
|
$ qfg sync --watch --dir ./our-config --interval 30
|
|
2086
2105
|
```
|
|
2087
2106
|
|
|
2088
|
-
_See code: [src/commands/sync.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
2107
|
+
_See code: [src/commands/sync.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/sync.ts)_
|
|
2089
2108
|
|
|
2090
2109
|
## `qfg toggle [NAME]`
|
|
2091
2110
|
|
|
2092
|
-
Set the
|
|
2111
|
+
Set the fallback value for a flag or config in one environment.
|
|
2093
2112
|
|
|
2094
2113
|
```
|
|
2095
2114
|
USAGE
|
|
2096
2115
|
$ qfg toggle [NAME] [--json] [--interactive] [--no-color] [--verbose] [-w <value>] [--confidential]
|
|
2097
|
-
[--env-var <value>] [--environment <value>] [--value <value>] [--confirm] [--secret]
|
|
2116
|
+
[--env-var <value>] [--environment <value>] [--replace-targeting] [--value <value>] [--confirm] [--secret]
|
|
2117
|
+
[--secret-key-name <value>]
|
|
2098
2118
|
|
|
2099
2119
|
ARGUMENTS
|
|
2100
2120
|
NAME config/feature-flag/etc. name
|
|
@@ -2104,6 +2124,8 @@ FLAGS
|
|
|
2104
2124
|
--confirm confirm without prompt
|
|
2105
2125
|
--env-var=<value> environment variable to use as default value
|
|
2106
2126
|
--environment=<value> environment to change
|
|
2127
|
+
--replace-targeting set the value for EVERYONE: delete this environment's targeting rules instead of keeping
|
|
2128
|
+
them (they stay in git history)
|
|
2107
2129
|
--secret encrypt the value of this item
|
|
2108
2130
|
--secret-key-name=<value> [default: quonfig.secrets.encryption.key] name of the secret key to use for
|
|
2109
2131
|
encryption/decryption
|
|
@@ -2117,15 +2139,17 @@ GLOBAL FLAGS
|
|
|
2117
2139
|
--verbose Verbose output
|
|
2118
2140
|
|
|
2119
2141
|
DESCRIPTION
|
|
2120
|
-
Set the
|
|
2142
|
+
Set the fallback value for a flag or config in one environment.
|
|
2121
2143
|
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2144
|
+
The fallback is the unconditional rule at the end of the environment's rule
|
|
2145
|
+
list: what users receive when no targeting rule matches. Targeting rules and
|
|
2146
|
+
percentage rollouts above it are kept, and the command tells you how many.
|
|
2147
|
+
If the environment has no rules of its own yet, they are copied from the
|
|
2148
|
+
flag's default rules first, so inherited targeting is kept too.
|
|
2125
2149
|
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2150
|
+
To turn a flag on or off for EVERYONE, including users matched by targeting
|
|
2151
|
+
rules, add --replace-targeting. This deletes the environment's targeting
|
|
2152
|
+
rules (they stay in git history).
|
|
2129
2153
|
|
|
2130
2154
|
To set a percentage rollout (gradual rollout / A/B test / canary deploy) instead:
|
|
2131
2155
|
qfg set-rollout my.flag --environment production --true-percent 20
|
|
@@ -2141,7 +2165,7 @@ EXAMPLES
|
|
|
2141
2165
|
|
|
2142
2166
|
$ qfg toggle my.flag.name --value=true --environment=staging
|
|
2143
2167
|
|
|
2144
|
-
$ qfg toggle my.flag.name --value=false --environment=production # kill-switch:
|
|
2168
|
+
$ qfg toggle my.flag.name --value=false --environment=production --replace-targeting # kill-switch: off for everyone
|
|
2145
2169
|
|
|
2146
2170
|
$ qfg toggle my.flag.name --value=true --secret
|
|
2147
2171
|
|
|
@@ -2187,7 +2211,7 @@ EXAMPLES
|
|
|
2187
2211
|
$ qfg verify --json
|
|
2188
2212
|
```
|
|
2189
2213
|
|
|
2190
|
-
_See code: [src/commands/verify.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
2214
|
+
_See code: [src/commands/verify.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/verify.ts)_
|
|
2191
2215
|
|
|
2192
2216
|
## `qfg whoami`
|
|
2193
2217
|
|
|
@@ -2210,7 +2234,7 @@ EXAMPLES
|
|
|
2210
2234
|
$ qfg whoami
|
|
2211
2235
|
```
|
|
2212
2236
|
|
|
2213
|
-
_See code: [src/commands/whoami.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
2237
|
+
_See code: [src/commands/whoami.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/whoami.ts)_
|
|
2214
2238
|
|
|
2215
2239
|
## `qfg workspace`
|
|
2216
2240
|
|
|
@@ -2233,7 +2257,7 @@ EXAMPLES
|
|
|
2233
2257
|
$ qfg workspace
|
|
2234
2258
|
```
|
|
2235
2259
|
|
|
2236
|
-
_See code: [src/commands/workspace.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
2260
|
+
_See code: [src/commands/workspace.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/workspace.ts)_
|
|
2237
2261
|
|
|
2238
2262
|
## `qfg workspace bootstrap`
|
|
2239
2263
|
|
|
@@ -2266,7 +2290,7 @@ EXAMPLES
|
|
|
2266
2290
|
$ qfg workspace bootstrap --dir ./our-config --skip-validate
|
|
2267
2291
|
```
|
|
2268
2292
|
|
|
2269
|
-
_See code: [src/commands/workspace/bootstrap.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
2293
|
+
_See code: [src/commands/workspace/bootstrap.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/workspace/bootstrap.ts)_
|
|
2270
2294
|
|
|
2271
2295
|
## `qfg workspace create SLUG`
|
|
2272
2296
|
|
|
@@ -2300,7 +2324,7 @@ EXAMPLES
|
|
|
2300
2324
|
$ qfg workspace create my-team --org 11111111-1111-1111-1111-111111111111
|
|
2301
2325
|
```
|
|
2302
2326
|
|
|
2303
|
-
_See code: [src/commands/workspace/create.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
2327
|
+
_See code: [src/commands/workspace/create.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/workspace/create.ts)_
|
|
2304
2328
|
|
|
2305
2329
|
## `qfg workspace switch [SLUG]`
|
|
2306
2330
|
|
|
@@ -2328,7 +2352,7 @@ EXAMPLES
|
|
|
2328
2352
|
$ qfg workspace switch acme/production
|
|
2329
2353
|
```
|
|
2330
2354
|
|
|
2331
|
-
_See code: [src/commands/workspace/switch.ts](https://github.com/quonfig/cli/blob/v0.0.
|
|
2355
|
+
_See code: [src/commands/workspace/switch.ts](https://github.com/quonfig/cli/blob/v0.0.73/src/commands/workspace/switch.ts)_
|
|
2332
2356
|
<!-- commandsstop -->
|
|
2333
2357
|
|
|
2334
2358
|
## Local Development
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { Flags } from '@oclif/core';
|
|
2
2
|
import { APICommand } from '../../index.js';
|
|
3
3
|
import nameArg from '../../util/name-arg.js';
|
|
4
|
+
import { isCatchAllRule } from '../../util/rules.js';
|
|
4
5
|
function startOfDayUtcMs(date) {
|
|
5
6
|
return Date.UTC(date.getUTCFullYear(), date.getUTCMonth(), date.getUTCDate());
|
|
6
7
|
}
|
|
@@ -26,7 +27,10 @@ function formatRuleValue(value) {
|
|
|
26
27
|
function summarizeRules(rules) {
|
|
27
28
|
if (!rules || rules.length === 0)
|
|
28
29
|
return '[inherit default]';
|
|
29
|
-
|
|
30
|
+
// Both catch-all spellings count as the fallback (qfg-9kr8): a strict
|
|
31
|
+
// single-ALWAYS_TRUE find reported a targeting rule's value as the fallback
|
|
32
|
+
// for every scope written by an older `qfg set-default`.
|
|
33
|
+
const fallback = rules.find((r) => isCatchAllRule(r));
|
|
30
34
|
const overrides = rules.filter((r) => r !== fallback);
|
|
31
35
|
const fallbackStr = fallback ? formatRuleValue(fallback.value) : formatRuleValue(rules[0].value);
|
|
32
36
|
if (overrides.length === 0)
|
|
@@ -17,8 +17,13 @@ RULE EVALUATION
|
|
|
17
17
|
────────────────────────────────────────────────────────────
|
|
18
18
|
Rules are evaluated in ORDER — the FIRST matching rule wins.
|
|
19
19
|
Put specific rules (user lists, segments) BEFORE catch-all rules.
|
|
20
|
-
criteria: [
|
|
20
|
+
criteria: [{"operator": "ALWAYS_TRUE"}]
|
|
21
|
+
means "match everyone" (unconditional / catch-all).
|
|
22
|
+
This is the canonical spelling — write this one.
|
|
23
|
+
criteria: [] also accepted, and treated as unconditional. Older
|
|
24
|
+
"qfg set-default" / "qfg set-rollout" writes use it.
|
|
21
25
|
criteria: [..] multiple entries in one rule are ANDed together
|
|
26
|
+
criteria is REQUIRED on every rule — omitting the key is invalid.
|
|
22
27
|
|
|
23
28
|
────────────────────────────────────────────────────────────
|
|
24
29
|
EXAMPLE: complex targeting + rollout in production
|
|
@@ -34,7 +39,7 @@ Four rules in order:
|
|
|
34
39
|
"type": "feature_flag",
|
|
35
40
|
"valueType": "bool",
|
|
36
41
|
"default": {
|
|
37
|
-
"rules": [{ "criteria": [], "value": { "type": "bool", "value": false } }]
|
|
42
|
+
"rules": [{ "criteria": [{ "operator": "ALWAYS_TRUE" }], "value": { "type": "bool", "value": false } }]
|
|
38
43
|
},
|
|
39
44
|
"environments": [{
|
|
40
45
|
"id": "production",
|
|
@@ -62,7 +67,7 @@ Four rules in order:
|
|
|
62
67
|
"value": { "type": "bool", "value": false }
|
|
63
68
|
},
|
|
64
69
|
{
|
|
65
|
-
"criteria": [],
|
|
70
|
+
"criteria": [{ "operator": "ALWAYS_TRUE" }],
|
|
66
71
|
"value": {
|
|
67
72
|
"type": "weighted_values",
|
|
68
73
|
"value": {
|