@rayul/kordis 0.6.3 → 0.6.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.
Files changed (2) hide show
  1. package/dist/index.js +45 -8
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -224,13 +224,13 @@ var init_user = __esm({
224
224
  bio: z5.string().max(500).nullable(),
225
225
  avatar_url: UrlSchema.nullable(),
226
226
  is_verified: z5.boolean(),
227
- package_count: z5.number().int().nonnegative(),
228
227
  follower_count: z5.number().int().nonnegative(),
229
228
  created_at: IsoDateTimeSchema
230
229
  });
231
230
  SelfUserSchema = PublicUserSchema.extend({
232
231
  primary_provider: OAuthProviderSchema,
233
232
  role: UserRoleSchema,
233
+ package_count: z5.number().int().nonnegative(),
234
234
  following_count: z5.number().int().nonnegative(),
235
235
  last_active_at: IsoDateTimeSchema.nullable()
236
236
  });
@@ -386,7 +386,15 @@ var init_comment = __esm({
386
386
  is_edited: z7.boolean(),
387
387
  edited_at: IsoDateTimeSchema.nullable(),
388
388
  is_deleted: z7.boolean(),
389
- created_at: IsoDateTimeSchema
389
+ created_at: IsoDateTimeSchema,
390
+ /**
391
+ * Web permalink (`https://kordis.store/p/<full_slug>#comment-<id>`). Server
392
+ * populates whenever it has the package slug at serialization time —
393
+ * always on create + list paths; absent on update/status paths that don't
394
+ * carry the slug. Old API responses (pre-0.6.4) omit it; new clients use
395
+ * it directly when present (e.g., "✓ comment posted — view: <permalink>").
396
+ */
397
+ permalink: z7.string().url().optional()
390
398
  });
391
399
  CommentTreeSchema = CommentSchema.extend({
392
400
  replies: z7.lazy(() => z7.array(CommentTreeSchema))
@@ -1887,7 +1895,7 @@ var SORT_MODES = [
1887
1895
  ];
1888
1896
  var TIME_WINDOWS = ["24h", "7d", "30d"];
1889
1897
  function searchCommand() {
1890
- return new Command3("search").description("search the Kordis registry").argument("[query...]", "keywords to match against title/description").option("--type <type>", "filter by harness type (skill|mcp-server|project-rules|custom-agent|hook)").option("--tool <tool>", "filter by compatible tool (claude-code|codex|cursor|...)").option("--tier <tier>", "filter by portability tier (A|B|C|D)").option("--sort <mode>", `sort: ${SORT_MODES.join("|")}`).option("--trending", "list trending packages (overrides --sort)", false).option("--rising", "list rising packages by 7d acceleration (overrides --sort)", false).option("--window <w>", `time window for --trending: ${TIME_WINDOWS.join("|")}`, "24h").option("--limit <n>", "max results", (v) => parseInt(v, 10), 20).action(async (query, opts) => {
1898
+ return new Command3("search").description("search the Kordis registry").argument("[query...]", "keywords to match against title/description").option("--type <type>", "filter by harness type (skill|mcp-server|project-rules|custom-agent|hook)").option("--tool <tool>", "filter by compatible tool (claude-code|codex|cursor|...)").option("--tier <tier>", "filter by portability tier (A|B|C|D)").option("--author <username>", "filter to a single author (server returns exact total when set)").option("--sort <mode>", `sort: ${SORT_MODES.join("|")}`).option("--trending", "list trending packages (overrides --sort)", false).option("--rising", "list rising packages by 7d acceleration (overrides --sort)", false).option("--window <w>", `time window for --trending: ${TIME_WINDOWS.join("|")}`, "24h").option("--limit <n>", "max results", (v) => parseInt(v, 10), 20).action(async (query, opts) => {
1891
1899
  if (opts.sort && !SORT_MODES.includes(opts.sort)) {
1892
1900
  throw new Error(`--sort must be one of ${SORT_MODES.join(", ")}`);
1893
1901
  }
@@ -1913,6 +1921,7 @@ function searchCommand() {
1913
1921
  type: opts.type ? [opts.type] : void 0,
1914
1922
  tool: opts.tool ? [opts.tool] : void 0,
1915
1923
  tier: opts.tier,
1924
+ ...opts.author ? { author: opts.author } : {},
1916
1925
  sort: opts.sort ?? "relevance",
1917
1926
  limit: opts.limit
1918
1927
  });
@@ -1944,6 +1953,14 @@ function searchCommand() {
1944
1953
  }
1945
1954
  return;
1946
1955
  }
1956
+ if (typeof res.total === "number") {
1957
+ printHuman(
1958
+ c.gray(
1959
+ `Showing ${res.results.length} of ${res.total} match${res.total === 1 ? "" : "es"}`
1960
+ )
1961
+ );
1962
+ printHuman("");
1963
+ }
1947
1964
  for (const p of res.results) {
1948
1965
  printHuman(
1949
1966
  `${c.bold(p.full_slug)} ${c.gray(`v${p.current_version}`)} ${c.cyan(`[${p.type}]`)}`
@@ -2557,6 +2574,10 @@ function pushCommand() {
2557
2574
  content = ensureTypeField(content, "skill");
2558
2575
  } else {
2559
2576
  content = await readFile6(abs, "utf8");
2577
+ const isSkillFilename = abs.endsWith("/SKILL.md") || abs.endsWith(".skill.md");
2578
+ if (isSkillFilename) {
2579
+ content = ensureTypeField(content, "skill");
2580
+ }
2560
2581
  }
2561
2582
  let nameFromFm = null;
2562
2583
  try {
@@ -3814,6 +3835,9 @@ function commentCommand() {
3814
3835
  const meta = [`kind: ${res.kind}`];
3815
3836
  if (res.title) meta.push(`title: "${res.title}"`);
3816
3837
  printHuman(` ${meta.join(" \xB7 ")}`);
3838
+ if (res.permalink) {
3839
+ printHuman(c.gray(` view: ${res.permalink}`));
3840
+ }
3817
3841
  }
3818
3842
  });
3819
3843
  }
@@ -4330,11 +4354,24 @@ function recommendCommand() {
4330
4354
  human: () => {
4331
4355
  if (res.items.length === 0) {
4332
4356
  printHuman(c.yellow("(no recommendations available right now)"));
4333
- printHuman(
4334
- c.gray(
4335
- " \u2192 registry may be sparse; try `kordis search --trending` for broader discovery"
4336
- )
4337
- );
4357
+ if (!res.personalized) {
4358
+ printHuman(
4359
+ c.gray(
4360
+ " \u2192 personalization is OFF, so the server ranks on popularity alone \u2014 likely empty pool."
4361
+ )
4362
+ );
4363
+ printHuman(
4364
+ c.gray(
4365
+ " \u2192 enable for stack-aware matches: `kordis setup --personalization on` (no Y/n prompt \u2014 agent-friendly; confirm with the user first)"
4366
+ )
4367
+ );
4368
+ } else {
4369
+ printHuman(
4370
+ c.gray(
4371
+ " \u2192 personalization is ON but no matches for your stack \u2014 registry may be sparse for this profile. Try `kordis search <topic>` or `kordis search --trending`."
4372
+ )
4373
+ );
4374
+ }
4338
4375
  return;
4339
4376
  }
4340
4377
  printHuman(
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rayul/kordis",
3
- "version": "0.6.3",
3
+ "version": "0.6.4",
4
4
  "private": false,
5
5
  "description": "Command-line client for the Kordis registry — discover, install, and publish agentic-coding packages.",
6
6
  "license": "MIT",