@repokit/core 4.0.5 → 5.0.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.
Files changed (68) hide show
  1. package/README.md +17 -4
  2. package/dist/types.d.mts +1 -1
  3. package/externals/TSCompiler.ts +1 -2
  4. package/externals/types.ts +1 -1
  5. package/package.json +29 -20
  6. package/Cargo.lock +0 -1609
  7. package/Cargo.toml +0 -23
  8. package/installation/install.sh +0 -99
  9. package/internals/argv/argv.rs +0 -132
  10. package/internals/argv/mod.rs +0 -1
  11. package/internals/caches/crawl_cache.rs +0 -126
  12. package/internals/caches/file_cache.rs +0 -104
  13. package/internals/caches/mod.rs +0 -6
  14. package/internals/caches/old_cache.rs +0 -35
  15. package/internals/caches/repokit_version_resolver.rs +0 -50
  16. package/internals/caches/settings_cache.rs +0 -73
  17. package/internals/caches/version_cache.rs +0 -142
  18. package/internals/context/cache_scope.rs +0 -71
  19. package/internals/context/file_system.rs +0 -66
  20. package/internals/context/git_scope.rs +0 -55
  21. package/internals/context/mod.rs +0 -5
  22. package/internals/context/node_scope.rs +0 -133
  23. package/internals/context/typescript_bridge.rs +0 -84
  24. package/internals/executables/internal_executable.rs +0 -15
  25. package/internals/executables/internal_executable_definition.rs +0 -40
  26. package/internals/executables/mod.rs +0 -2
  27. package/internals/executor/executor.rs +0 -88
  28. package/internals/executor/mod.rs +0 -1
  29. package/internals/file_walker/file_walker.rs +0 -69
  30. package/internals/file_walker/mod.rs +0 -2
  31. package/internals/file_walker/walker.rs +0 -114
  32. package/internals/internal_commands/help.rs +0 -174
  33. package/internals/internal_commands/internal_registry.rs +0 -34
  34. package/internals/internal_commands/list_commands.rs +0 -97
  35. package/internals/internal_commands/list_owners.rs +0 -61
  36. package/internals/internal_commands/list_themes.rs +0 -114
  37. package/internals/internal_commands/list_version.rs +0 -59
  38. package/internals/internal_commands/locate_command.rs +0 -77
  39. package/internals/internal_commands/mod.rs +0 -11
  40. package/internals/internal_commands/onboarder.rs +0 -60
  41. package/internals/internal_commands/register_command.rs +0 -99
  42. package/internals/internal_commands/search_commands.rs +0 -201
  43. package/internals/internal_commands/upgrade_repokit.rs +0 -71
  44. package/internals/internal_filesystem/file_builder.rs +0 -56
  45. package/internals/internal_filesystem/mod.rs +0 -1
  46. package/internals/logger/logger.rs +0 -163
  47. package/internals/logger/mod.rs +0 -1
  48. package/internals/main.rs +0 -23
  49. package/internals/post_processing/mod.rs +0 -1
  50. package/internals/post_processing/post_processor.rs +0 -37
  51. package/internals/repokit/command_definition.rs +0 -11
  52. package/internals/repokit/mod.rs +0 -6
  53. package/internals/repokit/repokit.rs +0 -146
  54. package/internals/repokit/repokit_command.rs +0 -101
  55. package/internals/repokit/repokit_config.rs +0 -101
  56. package/internals/repokit/repokit_construct_validator.rs +0 -11
  57. package/internals/repokit/repokit_runtime.rs +0 -43
  58. package/internals/themes/built_in_themes/mod.rs +0 -3
  59. package/internals/themes/built_in_themes/money.rs +0 -41
  60. package/internals/themes/built_in_themes/seeing_red.rs +0 -41
  61. package/internals/themes/built_in_themes/the_blues.rs +0 -41
  62. package/internals/themes/mod.rs +0 -5
  63. package/internals/themes/theme.rs +0 -108
  64. package/internals/themes/theme_colors.rs +0 -32
  65. package/internals/themes/theme_inputs.rs +0 -35
  66. package/internals/themes/theme_registry.rs +0 -123
  67. package/internals/validations/command_validations.rs +0 -127
  68. package/internals/validations/mod.rs +0 -1
package/README.md CHANGED
@@ -4,7 +4,7 @@
4
4
 
5
5
  A knowledgebase for your repository - wrapped in a CLI.
6
6
 
7
- Repokit is designed for large teams in complex codebases to publish self-documenting commands, API's, and workflows to a central CLI.
7
+ Repokit is designed for large teams in complex codebases to publish self-documenting commands, API's, and workflows to a central repository-owned CLI.
8
8
 
9
9
  The Repokit CLI exists as a living source of documentation and knowledge - growing alongside your team.
10
10
 
@@ -12,7 +12,20 @@ The Repokit CLI exists as a living source of documentation and knowledge - growi
12
12
 
13
13
  ### Installation
14
14
 
15
- If you do not have node.js setup in your repository, you'll first want to install node.js.
15
+ Installation requires `rust` and `node.js` installed on your machine
16
+
17
+ #### Rust Installation
18
+
19
+ ```bash
20
+ # install rust
21
+ curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
22
+ # install repokit
23
+ cargo install repokit
24
+ ```
25
+
26
+ #### Node.js
27
+
28
+ If you do not have node.js setup on your machine, you'll first want to install node.js.
16
29
 
17
30
  [NVM is a popular posix compliant installer](https://github.com/nvm-sh/nvm)
18
31
 
@@ -25,10 +38,10 @@ npm init
25
38
  If you don't have `typescript` already setup in your repository, you can run:
26
39
 
27
40
  ```bash
28
- npm i -D typescript && tsc --init
41
+ npm i -D typescript && npx tsc --init
29
42
  ```
30
43
 
31
- Next, install repokit:
44
+ Next, install repokit's command definition library:
32
45
 
33
46
  ```bash
34
47
  npm i -D @repokit/core
package/dist/types.d.mts CHANGED
@@ -1,7 +1,7 @@
1
1
  import { RepoKitConfig } from "./RepoKitConfig.mjs";
2
2
 
3
3
  //#region externals/types.d.ts
4
- interface IRepoKitConfig extends Omit<Partial<RepoKitConfig>, "project"> {
4
+ interface IRepoKitConfig extends Omit<Partial<RepoKitConfig>, "project" | "toScoped"> {
5
5
  project: string;
6
6
  }
7
7
  interface IRepoKitCommand {
@@ -1,5 +1,4 @@
1
- import type { RegisterOptions } from "ts-node";
2
- import { register } from "ts-node";
1
+ import { register, type RegisterOptions } from "ts-node";
3
2
 
4
3
  import type { UnwrappedBrigdeOperation } from "./types";
5
4
 
@@ -2,7 +2,7 @@ import type { RepoKitConfig } from "./RepoKitConfig";
2
2
 
3
3
  export interface IRepoKitConfig extends Omit<
4
4
  Partial<RepoKitConfig>,
5
- "project"
5
+ "project" | "toScoped"
6
6
  > {
7
7
  project: string;
8
8
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@repokit/core",
3
- "version": "4.0.5",
3
+ "version": "5.0.0",
4
4
  "description": "A knowledgebase for your repository - wrapped in a CLI",
5
5
  "keywords": [
6
6
  "cli",
@@ -18,11 +18,7 @@
18
18
  "files": [
19
19
  "media",
20
20
  "dist",
21
- "externals",
22
- "internals",
23
- "installation",
24
- "Cargo.lock",
25
- "Cargo.toml"
21
+ "externals"
26
22
  ],
27
23
  "main": "./dist/index.mjs",
28
24
  "module": "./dist/index.mjs",
@@ -31,19 +27,19 @@
31
27
  "access": "public"
32
28
  },
33
29
  "scripts": {
34
- "build:all": "pnpm lint:ts && pnpm lint:rust && pnpm install:rust",
35
- "build:rust": "cargo build --release",
30
+ "build": "pnpm build:debug --release",
31
+ "build:debug": "pnpm build:ts && cargo build",
36
32
  "build:ts": "tsx devserver/run.ts",
37
33
  "clean:ts": "tsx devserver/run.ts -c",
38
- "grant:exec": "chmod -R +x ./installation",
39
- "install:rust": "pnpm build:rust && cargo install --path .",
40
- "lint:all": "pnpm lint:ts && pnpm lint:rust",
41
- "lint:rust": "cargo clippy --fix --allow-dirty",
42
- "lint:ts": "oxlint --type-aware --type-check --report-unused-disable-directives --fix && oxfmt",
34
+ "format:toml": "taplo lint && taplo format",
35
+ "lint:all": "pnpm lint:rust && pnpm lint:ts",
36
+ "lint:rust": "cargo clippy --fix --allow-dirty --allow-no-vcs && pnpm format:toml",
37
+ "lint:rust:ci": "cargo clippy --fix",
38
+ "lint:ts": "oxlint --type-aware --report-unused-disable-directives --fix && oxfmt",
43
39
  "package:ts": "pnpm lint:ts && pnpm lint:rust && pnpm build:ts",
44
- "postinstall": "pnpm grant:exec && ./installation/install.sh",
45
- "repokit": "pnpm install:rust && repokit",
46
- "run:dev": "pnpm build:ts && cargo run --package repokit --bin repokit",
40
+ "prepare": "husky",
41
+ "release": "tsx release/run.ts",
42
+ "run:dev": "pnpm build:ts && cargo run --bin repokit",
47
43
  "watch:ts": "tsx devserver/run.ts -w"
48
44
  },
49
45
  "dependencies": {
@@ -54,14 +50,27 @@
54
50
  "devDependencies": {
55
51
  "@figliolia/child-process": "^1.0.4",
56
52
  "@figliolia/semver": "^1.0.0",
53
+ "@taplo/cli": "^0.7.0",
57
54
  "@types/node": "^25.3.0",
58
- "chalk": "^5.6.2",
59
- "oxfmt": "^0.47.0",
55
+ "husky": "^9.1.7",
56
+ "lint-staged": "^17.0.2",
57
+ "oxfmt": "^0.53.0",
60
58
  "oxlint": "^1.42.0",
61
- "oxlint-tsgolint": "^0.22.0",
62
- "tsdown": "^0.21.0",
59
+ "oxlint-tsgolint": "^0.23.0",
60
+ "tsdown": "^0.22.0",
63
61
  "tsx": "^4.21.0",
64
62
  "typescript": "^6.0.2"
65
63
  },
64
+ "lint-staged": {
65
+ "*.@(js|ts|tsx|yml|yaml|md|json)": [
66
+ "pnpm lint:ts"
67
+ ],
68
+ "*.toml": [
69
+ "pnpm format:toml"
70
+ ],
71
+ "*.rs": [
72
+ "pnpm lint:rust"
73
+ ]
74
+ },
66
75
  "packageManager": "pnpm@10.33.2"
67
76
  }