@ooneex/cli 1.36.5 → 1.38.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/index.js CHANGED
@@ -10876,6 +10876,192 @@ git commit -m "chore(common): Update dependencies and cache package"
10876
10876
  Apply all coding conventions from the \`optimize\` skill.
10877
10877
  `;
10878
10878
 
10879
+ // src/templates/claude/skills/issue.create.md.txt
10880
+ var issue_create_md_default = "---\nname: issue:create\ndescription: Create a new YAML issue file in modules/<module>/issues/ by gathering title, state, priority, labels, description, and module from the user, then running oo issue:create.\n---\n\n# Issue Create\n\nGather issue details from the user and create a new YAML issue file using the `oo issue:create` command.\n\n## Important\n\nAlways run all commands from the **root of the project** (the monorepo root), not from inside individual packages.\n\n## Workflow\n\n### 1. Gather Issue Details\n\nCollect the following from the user (ask only for missing values; infer reasonable defaults for the rest):\n\n| Field | Default | Valid values |\n|-------|---------|--------------|\n| `title` | \u2014 (required) | Any non-empty string |\n| `module` | `shared` | Any module name under `modules/` |\n| `state` | `Todo` | `Backlog`, `Todo`, `In Progress`, `In Review`, `Done`, `Cancelled` |\n| `priority` | `Medium` | `Low`, `Medium`, `High`, `Urgent` |\n| `labels` | `[]` | Comma-separated list |\n| `description` | `null` | Free-form text |\n\nIf the user provides a free-form description, use it as-is \u2014 `/issue:improve` will structure it later.\n\n### 2. Run the Create Command\n\n```bash\noo issue:create \\\n --title=\"<title>\" \\\n --module=<module> \\\n --state=\"<state>\" \\\n --priority=\"<priority>\" \\\n [--labels=\"<label1>,<label2>\"] \\\n [--description=\"<description>\"]\n```\n\nThe command writes a YAML skeleton to `modules/<module>/issues/<ID>.yml` where `<ID>` is an auto-generated identifier (e.g. `ABC-012345`).\n\n### 3. Confirm Creation\n\nReport the path of the created file (e.g. `modules/shared/issues/ABC-012345.yml`) and the assigned ID.\n\n### 4. Suggest Next Steps\n\nAfter creating the file, suggest:\n\n- `/issue:improve` \u2014 to rewrite the description into a structured format with Context, Goal, Acceptance Criteria, and optional Technical Notes\n- `/issue:fix` \u2014 to implement the issue once it is ready\n\n## YAML Structure Reference\n\n```yaml\nid: \"ABC-012345\"\ntitle: \"Add user validation\"\nstate: \"Todo\"\npriority: \"Medium\"\ndescription: null\nlabels: []\n```\n\n## Notes\n\n- If the user already provided all required details, skip interactive prompting and run the command directly.\n- Never invent a title \u2014 always use exactly what the user provided.\n- If `--module` is unknown, default to `shared` and inform the user.\n";
10881
+
10882
+ // src/templates/claude/skills/issue.fix.txt
10883
+ var issue_fix_default = `---
10884
+ name: issue:fix
10885
+ description: Find an issue by ID in a module and implement it. Reads modules/<module>/issues/<ID>.yml, then creates or updates entities, repositories, services, controllers/commands, and optional resources.
10886
+ ---
10887
+
10888
+ # Issue Fix
10889
+
10890
+ Locate the issue YAML file for the provided module and ID, then implement it.
10891
+
10892
+ ## Important
10893
+
10894
+ Always run all commands from the **root of the project** (the monorepo root), not from inside individual packages.
10895
+
10896
+ ## Steps
10897
+
10898
+ ### 1. Locate and read the issue YML
10899
+
10900
+ The user must provide:
10901
+ - \`--module\` \u2014 the module name (e.g. \`user\`, \`company\`, \`shared\`)
10902
+ - \`--id\` \u2014 the issue identifier (e.g. \`ENG-45\`, \`OON-123456\`)
10903
+
10904
+ Read the file at:
10905
+
10906
+ \`\`\`
10907
+ modules/<module>/issues/<ID>.yml
10908
+ \`\`\`
10909
+
10910
+ If the file does not exist, stop and tell the user the exact path that was checked.
10911
+
10912
+ An issue YML looks like:
10913
+
10914
+ \`\`\`yaml
10915
+ id: "ENG-45"
10916
+ title: "Add organization create feature"
10917
+ state: "In Progress"
10918
+ priority: "High"
10919
+ description: |
10920
+ ## Context
10921
+ \u2026
10922
+ ## Goal
10923
+ \u2026
10924
+ ## Acceptance Criteria
10925
+ - [ ] \u2026
10926
+ ## Technical Notes
10927
+ \u2026
10928
+ labels:
10929
+ - "Feature"
10930
+ - "API"
10931
+ resources:
10932
+ entity: OrganizationEntity
10933
+ repository: OrganizationRepository
10934
+ service: OrganizationCreateService
10935
+ controller: OrganizationCreateController
10936
+ permission: OrganizationPermission
10937
+ spec:
10938
+ name: "organization.create"
10939
+ entity: "organization"
10940
+ roles:
10941
+ - super_admin
10942
+ - admin
10943
+ permissions:
10944
+ - name: "organization:create"
10945
+ description: "Grants the ability to create a new organization"
10946
+ \`\`\`
10947
+
10948
+ ### 2. Analyse the issue
10949
+
10950
+ Extract:
10951
+
10952
+ - \`spec.name\` \u2014 dot-notation identifier (e.g. \`"user.create"\`)
10953
+ - \`spec.entity\` \u2014 the resource being acted on (e.g. \`"user"\`)
10954
+ - \`description\` \u2014 what the issue requires
10955
+ - \`spec.roles\` \u2014 list of roles with access; check \`modules/shared/src/roles.yml\` to map role slugs to their canonical values
10956
+ - \`spec.permissions\` \u2014 list of objects with \`name\` (\`"entity:action"\` format) and optional \`description\`
10957
+ - \`resources\` \u2014 map of resource keys to PascalCase class names; this is the authoritative list of what to create
10958
+
10959
+ Derive the HTTP method from the action part of \`spec.name\`:
10960
+ - \`.create\` \u2192 \`post\`
10961
+ - \`.read\` / \`.list\` / \`.search\` \u2192 \`get\`
10962
+ - \`.update\` \u2192 \`put\` or \`patch\`
10963
+ - \`.delete\` \u2192 \`delete\`
10964
+
10965
+ ### 3. Create or update the entity
10966
+
10967
+ Only if \`resources.entity\` is present.
10968
+
10969
+ \`\`\`
10970
+ /make:entity --name=<resources.entity> --module=<module>
10971
+ \`\`\`
10972
+
10973
+ ### 4. Create migrations for schema changes
10974
+
10975
+ If the entity introduces new columns, tables, or relations, create a migration using the \`/make:migration\` skill:
10976
+
10977
+ \`\`\`
10978
+ /make:migration --module=<module>
10979
+ \`\`\`
10980
+
10981
+ Implement the \`up()\` method with the required DDL (CREATE TABLE, ALTER TABLE, etc.) and the \`down()\` method to reverse it.
10982
+
10983
+ ### 5. Create or update the repository
10984
+
10985
+ Only if \`resources.repository\` is present.
10986
+
10987
+ \`\`\`
10988
+ /make:repository --name=<resources.repository> --module=<module>
10989
+ \`\`\`
10990
+
10991
+ Retain only the CRUD methods that are needed by this issue (e.g. \`.create\` needs \`save\`; \`.read\` needs \`findById\`; \`.list\` needs \`find\`; \`.delete\` needs \`delete\`).
10992
+
10993
+ ### 6. Create or update the service
10994
+
10995
+ Only if \`resources.service\` is present.
10996
+
10997
+ \`\`\`
10998
+ /make:service --name=<resources.service> --module=<module>
10999
+ \`\`\`
11000
+
11001
+ Inject the repository into the service via the constructor and implement \`execute()\` with the business logic described by the issue.
11002
+
11003
+ ### 7. Create or update the controller or command
11004
+
11005
+ **Controller** \u2014 only if \`resources.controller\` is present:
11006
+
11007
+ \`\`\`
11008
+ /make:controller --name=<resources.controller> --module=<module> --route-name=<spec.name> --route-path=<derived-path> --route-method=<derived-method>
11009
+ \`\`\`
11010
+
11011
+ Derive the route path from the entity and action (e.g. \`"user.create"\` \u2192 \`/users\`, \`"user.read"\` \u2192 \`/users/:id\`).
11012
+
11013
+ Inject the service into the controller. Set \`roles\` in the \`@Route\` decorator from \`spec.roles\` as uppercase string literals (e.g., \`"ROLE_USER"\`, \`"ROLE_ADMIN"\`). Apply each permission \`name\` from \`spec.permissions\` to the route decorator when a \`permissions\` field is available on \`@Route\`.
11014
+
11015
+ **Command** \u2014 only if \`resources.command\` is present:
11016
+
11017
+ \`\`\`
11018
+ /make:command --name=<resources.command> --module=<module>
11019
+ \`\`\`
11020
+
11021
+ Inject the service into the command. Set \`getName()\` to \`"<entity>:<action>"\` format.
11022
+
11023
+ ### 8. Create or update optional resources
11024
+
11025
+ Create each resource that is present in \`resources\` beyond the core four. Use the class name from the \`resources\` map as the \`--name\` value. Do not create resources that are absent from the map.
11026
+
11027
+ | \`resources\` key | Skill |
11028
+ |------------------|-----------------------------------------------------------------------------|
11029
+ | \`permission\` | \`/make:permission --name=<resources.permission> --module=<module>\` |
11030
+ | \`middleware\` | \`/make:middleware --name=<resources.middleware> --module=<module>\` |
11031
+ | \`cache\` | \`/make:cache --name=<resources.cache> --module=<module>\` |
11032
+ | \`pubsub\` | \`/make:pubsub --name=<resources.pubsub> --module=<module>\` |
11033
+ | \`mailer\` | \`/make:mailer --name=<resources.mailer> --module=<module>\` |
11034
+ | \`logger\` | \`/make:logger --name=<resources.logger> --module=<module>\` |
11035
+ | \`analytics\` | \`/make:analytics --name=<resources.analytics> --module=<module>\` |
11036
+ | \`storage\` | \`/make:storage --name=<resources.storage> --module=<module>\` |
11037
+ | \`cron\` | \`/make:cron --name=<resources.cron> --module=<module>\` |
11038
+ | \`ai\` | \`/make:ai --name=<resources.ai> --module=<module>\` |
11039
+ | \`database\` | \`/make:database --name=<resources.database> --module=<module>\` |
11040
+ | \`vectorDatabase\` | \`/make:vector-database --name=<resources.vectorDatabase> --module=<module>\` |
11041
+
11042
+ ### 9. Lint and format
11043
+
11044
+ \`\`\`bash
11045
+ bun run fmt
11046
+ bun run lint
11047
+ \`\`\`
11048
+
11049
+ ### 10. Confirm
11050
+
11051
+ Report:
11052
+
11053
+ - Issue \`id\` and \`title\` implemented
11054
+ - Resources created or updated (list each key and class name from \`resources\`)
11055
+ - Any step that was skipped and why
11056
+
11057
+ ## Notes
11058
+
11059
+ - The \`resources\` map is the single source of truth for what to create \u2014 do not infer additional resources beyond what is listed.
11060
+ - If a resource already exists, update it rather than overwrite it \u2014 add new methods, columns, or routes without removing existing ones unless they conflict.
11061
+ - Derive all names, paths, and methods from the issue; never ask the user for values that can be inferred.
11062
+ - Apply all coding conventions from the \`optimize\` skill to every generated file.
11063
+ `;
11064
+
10879
11065
  // src/templates/claude/skills/issue.improve.md.txt
10880
11066
  var issue_improve_md_default = `---
10881
11067
  name: issue:improve
@@ -10908,28 +11094,44 @@ Rewrite the \`description\` field into this structured format:
10908
11094
  ## Acceptance Criteria
10909
11095
  - [ ] <Condition 1 that must be met>
10910
11096
  - [ ] <Condition 2 that must be met>
11097
+ - [ ] <Entity> data model is defined
11098
+ - [ ] \`fieldName\` \u2014 <field description>
11099
+ - [ ] \`fieldName\` \u2014 <field description>
10911
11100
  - [ ] <\u2026>
10912
11101
 
10913
11102
  ## Technical Notes
10914
11103
  <Optional: technical constraints or implementation hints \u2014 omit section if not applicable>
10915
- \`\`\`
11104
+
11105
+ ### Data Model
11106
+ <List every entity involved and its relations using this format:>
11107
+ - \`EntityA.fieldName\` \u2192 \`@OneToMany(() => EntityB, (b) => b.a)\` \u2014 one A has many Bs
11108
+ - \`EntityB.fieldName\` \u2192 \`@ManyToOne(() => EntityA, (a) => a.bs)\` \u2014 many Bs belong to one A
11109
+ - \`EntityA.fieldName\` \u2192 \`@ManyToMany(() => EntityB)\` + \`@JoinTable()\` \u2014 pivot table owned by A
11110
+ - \`EntityA.fieldName\` \u2192 \`@OneToOne(() => EntityB)\` + \`@JoinColumn()\` \u2014 one-to-one, FK on A
10916
11111
 
10917
11112
  Rules:
10918
11113
  - Preserve all factual information from the original description
10919
11114
  - Keep each section concise and actionable
10920
11115
  - Acceptance Criteria must be checkboxes (\`- [ ]\`), not prose
11116
+ - When a criterion covers a data model, add indented sub-checkboxes (\` - [ ] \\\`fieldName\\\` \u2014 <description>\`) for each field of that entity
11117
+ - Field descriptions must be plain English \u2014 no TypeORM decorators, ENUM syntax, or implementation details (e.g. \`\` \`type\` \u2014 b2b | school | internal \`\`, not \`\` \`type\` \u2014 ENUM(b2b | school | internal) \`\`; \`\` \`createdAt\` \u2014 Created date \`\`, not \`\` \`createdAt\` \u2014 TIMESTAMPTZ via \`@CreateDateColumn\` \`\`; \`\` \`packs\` \u2014 One organization has many packs \`\`, not \`\` \`packs\` \u2014 \`@OneToMany(() => PackEntity, (p) => p.org)\` \`\`)
11118
+ - Field names must use the entity name, not an ID suffix \u2014 write \`\` \`address\` \u2014 User has one address \`\`, not \`\` \`addressId\` \u2014 Optional FK to address \`\`; write \`\` \`organization\` \u2014 Membership belongs to one organization \`\`, not \`\` \`organizationId\` \u2014 FK to organization \`\`
10921
11119
  - Omit \`## Technical Notes\` if there is nothing relevant to add
11120
+ - Omit \`## Technical Notes\` in the parent issue when it has sub-issues \u2014 add it only in sub-issues
11121
+ - When the issue is split, the parent \`## Acceptance Criteria\` must be the exact union of all sub-issues' criteria, grouped by sub-issue title \u2014 never written before sub-issues exist
10922
11122
 
10923
- ### 3. Extract Labels
11123
+ ### 3. Extract Labels and Set Priority
10924
11124
 
10925
- Based on the improved description, suggest relevant labels:
10926
- - Short (1\u20133 words), lowercase, hyphenated (e.g. \`bug\`, \`enhancement\`, \`performance\`, \`breaking-change\`)
11125
+ **Labels** \u2014 Based on the improved description, suggest relevant labels:
11126
+ - Short (1\u20133 words), properly cased: Title Case for general terms, uppercase for acronyms (e.g. \`Feature\`, \`Bug\`, \`API\`, \`Database\`, \`UI\`, \`Breaking Change\`)
10927
11127
  - Deduplicate against labels already present in the YAML
10928
- - Present suggestions to the user and ask which ones to add
10929
11128
 
10930
- Common label vocabulary:
10931
- \`bug\`, \`enhancement\`, \`performance\`, \`refactor\`, \`security\`, \`breaking-change\`,
10932
- \`documentation\`, \`testing\`, \`database\`, \`api\`, \`ui\`, \`infrastructure\`, \`cleanup\`
11129
+ Common label vocabulary (use these exact casings):
11130
+ \`Feature\`, \`Bug\`, \`Improvement\`, \`Enhancement\`, \`Performance\`, \`Refactor\`, \`Security\`, \`Breaking Change\`,
11131
+ \`Documentation\`, \`Testing\`, \`Database\`, \`API\`, \`UI\`, \`Infrastructure\`, \`Cleanup\`
11132
+
11133
+ **Priority** \u2014 Always set or confirm the \`priority\` field. Valid values: \`Urgent\`, \`High\`, \`Medium\`, \`Low\`.
11134
+ If no priority is set in the original file, infer one from the description.
10933
11135
 
10934
11136
  ### 4. Check Whether Splitting Is Needed
10935
11137
 
@@ -10948,6 +11150,28 @@ For each sub-issue:
10948
11150
  - Generate a new identifier using the format \`XXX-000000\` (3 uppercase letters + 6 digits)
10949
11151
  - Write a new YAML file to the same \`modules/<module>/issues/\` directory
10950
11152
  - Inherit \`state\`, \`priority\`, and \`labels\` from the parent issue
11153
+ - When the sub-issue involves entities or a data model, include a \`### Data Model\` subsection inside \`## Technical Notes\` that lists every relation with:
11154
+ - the exact field name on the owning entity
11155
+ - the TypeORM decorator (\`@OneToMany\`, \`@ManyToOne\`, \`@ManyToMany\`, \`@OneToOne\`)
11156
+ - the inverse field name and which side owns the foreign key / join table
11157
+
11158
+ Each sub-issue description must use the same structured format as the parent issue, including \`## Acceptance Criteria\` with checkboxes. The \`## Context\` and \`## Goal\` sections should be concise (2\u20133 sentences each) and scoped to the sub-issue.
11159
+
11160
+ After writing all sub-issues, update the parent issue's \`## Acceptance Criteria\` to be the exact union of all sub-issues' \`## Acceptance Criteria\` items, grouped under a labeled header per sub-issue:
11161
+
11162
+ \`\`\`markdown
11163
+ ## Acceptance Criteria
11164
+
11165
+ ### <Sub-issue title>
11166
+ - [ ] <Condition from sub-issue>
11167
+ - [ ] <\u2026>
11168
+
11169
+ ### <Sub-issue title>
11170
+ - [ ] <Condition from sub-issue>
11171
+ - [ ] <\u2026>
11172
+ \`\`\`
11173
+
11174
+ Do not invent new criteria \u2014 copy them verbatim from each sub-issue.
10951
11175
 
10952
11176
  Sub-issue YAML structure:
10953
11177
  \`\`\`yaml
@@ -10956,7 +11180,22 @@ title: "<action-oriented title: verb + noun>"
10956
11180
  state: "<parent state>"
10957
11181
  priority: "<parent priority>"
10958
11182
  description: |
10959
- <2\u20135 sentences: context, goal, and acceptance criteria>
11183
+ ## Context
11184
+ <2\u20133 sentences scoped to this sub-issue>
11185
+
11186
+ ## Goal
11187
+ <What this sub-issue specifically achieves>
11188
+
11189
+ ## Acceptance Criteria
11190
+ - [ ] <Condition 1>
11191
+ - [ ] <Condition 2>
11192
+ - [ ] <\u2026>
11193
+
11194
+ ## Technical Notes
11195
+ <Optional \u2014 omit if not applicable>
11196
+
11197
+ ### Data Model
11198
+ <Relations for entities involved in this sub-issue>
10960
11199
  labels:
10961
11200
  - "<label>"
10962
11201
  \`\`\`
@@ -10981,8 +11220,8 @@ description: |
10981
11220
  ## Acceptance Criteria
10982
11221
  - [ ] \u2026
10983
11222
  labels:
10984
- - "enhancement"
10985
- - "api"
11223
+ - "Enhancement"
11224
+ - "API"
10986
11225
  comments:
10987
11226
  - author: "Alice"
10988
11227
  message: "Some comment"
@@ -10992,7 +11231,6 @@ comments:
10992
11231
 
10993
11232
  - Never invent facts \u2014 only restructure and clarify what is already in the description
10994
11233
  - If the description is missing or empty, tell the user and stop
10995
- - Always show the user the improved description before writing, and ask for confirmation
10996
11234
  - When splitting, inform the user of each sub-issue file created
10997
11235
  `;
10998
11236
 
@@ -14147,6 +14385,8 @@ var skills = {
14147
14385
  "make.service": make_service_md_default,
14148
14386
  "make.storage": make_storage_md_default,
14149
14387
  "make.vector-database": make_vector_database_md_default,
14388
+ "issue.create": issue_create_md_default,
14389
+ "issue.fix": issue_fix_default,
14150
14390
  "issue.improve": issue_improve_md_default,
14151
14391
  commit: commit_md_default,
14152
14392
  optimize: optimize_md_default
@@ -14663,9 +14903,19 @@ import { decorator as decorator9 } from "@ooneex/command";
14663
14903
  import { TerminalLogger as TerminalLogger9 } from "@ooneex/logger";
14664
14904
 
14665
14905
  // src/templates/completions/_oo.txt
14666
- var _oo_default = `#compdef oo ooneex
14906
+ var _oo_default = `#compdef oo
14907
+
14908
+ _oo() {
14909
+ _ooneex "$@"
14910
+ }
14911
+
14912
+ _oo "$@"
14913
+ `;
14667
14914
 
14668
- _oo_modules() {
14915
+ // src/templates/completions/_ooneex.txt
14916
+ var _ooneex_default = `#compdef oo ooneex
14917
+
14918
+ _ooneex_modules() {
14669
14919
  local -a modules
14670
14920
  if [[ -d modules ]]; then
14671
14921
  modules=(\${(@f)"$(command ls -1 modules 2>/dev/null)"})
@@ -14673,7 +14923,7 @@ _oo_modules() {
14673
14923
  fi
14674
14924
  }
14675
14925
 
14676
- _oo_custom_commands() {
14926
+ _ooneex_custom_commands() {
14677
14927
  local -a cmds
14678
14928
  if [[ -d modules ]]; then
14679
14929
  cmds=(\${(@f)"$(command grep -rh -A1 'getName' modules/*/src/commands/*Command.ts 2>/dev/null | sed -n 's/.*return "\\(.*\\)".*/\\1/p' | sort -u)"})
@@ -14681,21 +14931,24 @@ _oo_custom_commands() {
14681
14931
  fi
14682
14932
  }
14683
14933
 
14684
- _oo() {
14934
+ _ooneex() {
14685
14935
  local -a commands
14686
14936
  commands=(
14687
14937
  'app\\:build:Build the application'
14938
+ 'app\\:create:Create a new application'
14688
14939
  'app\\:init:Initialize an application'
14689
14940
  'app\\:start:Start the application'
14690
14941
  'app\\:stop:Stop the application'
14942
+ 'claude\\:skill\\:create:Generate Claude skills from templates'
14691
14943
  'command\\:run:Run a custom command from a module'
14692
- 'completion\\:zsh:Install Zsh completion for oo command'
14944
+ 'completion\\:zsh:Install Zsh completion for ooneex command'
14693
14945
  'help:Show available commands'
14946
+ 'issue\\:create:Create a YAML skeleton file for a new issue'
14947
+ 'issue\\:pull:Pull an issue from Linear and save it as a YAML file'
14948
+ 'issue\\:push:Push a local issue YAML to Linear (create or update)'
14694
14949
  'make\\:ai:Generate a new AI class'
14695
14950
  'make\\:analytics:Generate a new analytics class'
14696
- 'app\\:create:Create a new application'
14697
14951
  'make\\:cache:Generate a new cache class'
14698
- 'claude\\:skill\\:create:Generate Claude skills from templates'
14699
14952
  'make\\:command:Generate a new command class'
14700
14953
  'make\\:controller:Generate a new controller class'
14701
14954
  'make\\:cron:Generate a new cron class'
@@ -14705,23 +14958,21 @@ _oo() {
14705
14958
  'make\\:logger:Generate a new logger class'
14706
14959
  'make\\:mailer:Generate a new mailer class'
14707
14960
  'make\\:middleware:Generate a new middleware class'
14708
- 'migration\\:create:Generate a new migration file'
14709
- 'migration\\:up:Run migrations for all modules'
14710
- 'module\\:create:Generate a new module'
14711
- 'module\\:lock:Lock module migrations by hashing their content into a yml file'
14712
- 'module\\:remove:Remove an existing module'
14713
14961
  'make\\:permission:Generate a new permission class'
14714
14962
  'make\\:pubsub:Generate a new PubSub event class'
14715
14963
  'make\\:release:Release packages with version bump, changelog, and git tag'
14716
14964
  'make\\:repository:Generate a new repository class'
14717
14965
  'make\\:resource\\:book:Generate book resource (entity, migration, repository)'
14718
- 'issue\\:create:Create a YAML skeleton file for a new issue'
14719
- 'issue\\:pull:Pull an issue from Linear and save it as a YAML file'
14720
- 'seed\\:create:Generate a new seed file'
14721
- 'seed\\:run:Run seeds for all modules'
14722
14966
  'make\\:service:Generate a new service class'
14723
14967
  'make\\:storage:Generate a new storage class'
14724
14968
  'make\\:vector-database:Generate a new vector database class'
14969
+ 'migration\\:create:Generate a new migration file'
14970
+ 'migration\\:up:Run migrations for all modules'
14971
+ 'module\\:create:Generate a new module'
14972
+ 'module\\:lock:Lock module migrations by hashing their content into a yml file'
14973
+ 'module\\:remove:Remove an existing module'
14974
+ 'seed\\:create:Generate a new seed file'
14975
+ 'seed\\:run:Run seeds for all modules'
14725
14976
  )
14726
14977
 
14727
14978
  _arguments -s \\
@@ -14731,66 +14982,11 @@ _oo() {
14731
14982
 
14732
14983
  case "$state" in
14733
14984
  cmds)
14734
- _describe -t commands 'oo command' commands
14985
+ _describe -t commands 'ooneex command' commands
14735
14986
  ;;
14736
14987
  opts)
14737
14988
  case "$words[1]" in
14738
- command:run)
14739
- _arguments -s \\
14740
- '1:command name:_oo_custom_commands'
14741
- ;;
14742
- make:controller)
14743
- _arguments -s \\
14744
- '--name=[Name of the resource]:name' \\
14745
- '--module=[Module name]:module:_oo_modules' \\
14746
- '--route-name=[Route name]:route_name' \\
14747
- '--route-path=[Route path]:route_path' \\
14748
- '--route-method=[Route HTTP method]:method:(GET POST PUT PATCH DELETE HEAD OPTIONS)' \\
14749
- '--is-socket[Socket mode]'
14750
- ;;
14751
- make:middleware)
14752
- _arguments -s \\
14753
- '--name=[Name of the resource]:name' \\
14754
- '--module=[Module name]:module:_oo_modules' \\
14755
- '--is-socket[Socket mode]'
14756
- ;;
14757
- make:entity)
14758
- _arguments -s \\
14759
- '--name=[Name of the resource]:name' \\
14760
- '--module=[Module name]:module:_oo_modules' \\
14761
- '--table-name=[Database table name]:table_name'
14762
- ;;
14763
- make:pubsub)
14764
- _arguments -s \\
14765
- '--name=[Name of the resource]:name' \\
14766
- '--module=[Module name]:module:_oo_modules' \\
14767
- '--channel=[Channel name]:channel'
14768
- ;;
14769
- migration:create)
14770
- _arguments -s \\
14771
- '--module=[Module name]:module:_oo_modules'
14772
- ;;
14773
- module:lock)
14774
- _arguments -s \\
14775
- '--module=[Module name]:module:_oo_modules' \\
14776
- '--override[Override already registered migrations]'
14777
- ;;
14778
- seed:create)
14779
- _arguments -s \\
14780
- '--name=[Name of the resource]:name' \\
14781
- '--module=[Module name]:module:_oo_modules'
14782
- ;;
14783
- module:create)
14784
- _arguments -s \\
14785
- '--name=[Name of the resource]:name'
14786
- ;;
14787
- module:remove)
14788
- _arguments -s \\
14789
- '--name=[Module name]:name:_oo_modules'
14790
- ;;
14791
- make:docker)
14792
- _arguments -s \\
14793
- '--name=[Docker service name]:name:(clickhouse elasticsearch grafana jaeger keycloak libretranslate maildev memcached minio mongodb mysql nats postgres prometheus rabbitmq redis temporal vault)'
14989
+ app:build|app:start|app:stop|claude:skill:create|completion:zsh|help|make:release|make:resource:book)
14794
14990
  ;;
14795
14991
  app:create)
14796
14992
  _arguments -s \\
@@ -14803,10 +14999,9 @@ _oo() {
14803
14999
  '--destination=[Destination path]:destination:_files -/' \\
14804
15000
  '--app-type=[Application type]:type:(cli api)'
14805
15001
  ;;
14806
- make:ai|make:analytics|make:cache|make:command|make:cron|make:database|make:logger|make:mailer|make:permission|make:repository|make:service|make:storage|make:vector-database)
15002
+ command:run)
14807
15003
  _arguments -s \\
14808
- '--name=[Name of the resource]:name' \\
14809
- '--module=[Module name]:module:_oo_modules'
15004
+ '1:command name:_ooneex_custom_commands'
14810
15005
  ;;
14811
15006
  issue:create)
14812
15007
  _arguments -s \\
@@ -14815,104 +15010,23 @@ _oo() {
14815
15010
  '--priority=[Issue priority]:priority:(Low Medium High Urgent)' \\
14816
15011
  '--description=[Issue description]:description' \\
14817
15012
  '*--labels=[Label (repeatable)]:label' \\
14818
- '--module=[Module name]:module:_oo_modules' \\
15013
+ '--module=[Module name]:module:_ooneex_modules' \\
14819
15014
  '--interactive[Prompt for all fields]'
14820
15015
  ;;
14821
15016
  issue:pull)
14822
15017
  _arguments -s \\
14823
15018
  '--id=[Linear issue ID or identifier]:id' \\
14824
- '--module=[Module name]:module:_oo_modules'
15019
+ '--module=[Module name]:module:_ooneex_modules'
14825
15020
  ;;
14826
- migration:up|seed:run)
15021
+ issue:push)
14827
15022
  _arguments -s \\
14828
- '--drop[Drop the database before running]'
14829
- ;;
14830
- app:build|app:start|app:stop|help|make:release|make:resource:book|claude:skill:create|completion:zsh)
15023
+ '--id=[Local issue ID to push]:id' \\
15024
+ '--module=[Module name]:module:_ooneex_modules'
14831
15025
  ;;
14832
- esac
14833
- ;;
14834
- esac
14835
- }
14836
-
14837
- _oo "$@"
14838
- `;
14839
-
14840
- // src/templates/completions/_ooneex.txt
14841
- var _ooneex_default = `#compdef oo ooneex
14842
-
14843
- _ooneex_modules() {
14844
- local -a modules
14845
- if [[ -d modules ]]; then
14846
- modules=(\${(@f)"$(command ls -1 modules 2>/dev/null)"})
14847
- compadd -a modules
14848
- fi
14849
- }
14850
-
14851
- _ooneex_custom_commands() {
14852
- local -a cmds
14853
- if [[ -d modules ]]; then
14854
- cmds=(\${(@f)"$(command grep -rh -A1 'getName' modules/*/src/commands/*Command.ts 2>/dev/null | sed -n 's/.*return "\\(.*\\)".*/\\1/p' | sort -u)"})
14855
- compadd -a cmds
14856
- fi
14857
- }
14858
-
14859
- _ooneex() {
14860
- local -a commands
14861
- commands=(
14862
- 'app\\:build:Build the application'
14863
- 'app\\:init:Initialize an application'
14864
- 'app\\:start:Start the application'
14865
- 'app\\:stop:Stop the application'
14866
- 'command\\:run:Run a custom command from a module'
14867
- 'completion\\:zsh:Install Zsh completion for oo command'
14868
- 'help:Show available commands'
14869
- 'make\\:ai:Generate a new AI class'
14870
- 'make\\:analytics:Generate a new analytics class'
14871
- 'app\\:create:Create a new application'
14872
- 'make\\:cache:Generate a new cache class'
14873
- 'claude\\:skill\\:create:Generate Claude skills from templates'
14874
- 'make\\:command:Generate a new command class'
14875
- 'make\\:controller:Generate a new controller class'
14876
- 'make\\:cron:Generate a new cron class'
14877
- 'make\\:database:Generate a new database class'
14878
- 'make\\:docker:Add a docker service to docker-compose.yml'
14879
- 'make\\:entity:Generate a new entity class'
14880
- 'make\\:logger:Generate a new logger class'
14881
- 'make\\:mailer:Generate a new mailer class'
14882
- 'make\\:middleware:Generate a new middleware class'
14883
- 'migration\\:create:Generate a new migration file'
14884
- 'migration\\:up:Run migrations for all modules'
14885
- 'module\\:create:Generate a new module'
14886
- 'module\\:lock:Lock module migrations by hashing their content into a yml file'
14887
- 'module\\:remove:Remove an existing module'
14888
- 'make\\:permission:Generate a new permission class'
14889
- 'make\\:pubsub:Generate a new PubSub event class'
14890
- 'make\\:release:Release packages with version bump, changelog, and git tag'
14891
- 'make\\:repository:Generate a new repository class'
14892
- 'make\\:resource\\:book:Generate book resource (entity, migration, repository)'
14893
- 'issue\\:create:Create a YAML skeleton file for a new issue'
14894
- 'issue\\:pull:Pull an issue from Linear and save it as a YAML file'
14895
- 'seed\\:create:Generate a new seed file'
14896
- 'seed\\:run:Run seeds for all modules'
14897
- 'make\\:service:Generate a new service class'
14898
- 'make\\:storage:Generate a new storage class'
14899
- 'make\\:vector-database:Generate a new vector database class'
14900
- )
14901
-
14902
- _arguments -s \\
14903
- '1:command:->cmds' \\
14904
- '*::options:->opts' \\
14905
- && return 0
14906
-
14907
- case "$state" in
14908
- cmds)
14909
- _describe -t commands 'oo command' commands
14910
- ;;
14911
- opts)
14912
- case "$words[1]" in
14913
- command:run)
15026
+ make:ai|make:analytics|make:cache|make:command|make:cron|make:database|make:logger|make:mailer|make:permission|make:repository|make:service|make:storage|make:vector-database)
14914
15027
  _arguments -s \\
14915
- '1:command name:_ooneex_custom_commands'
15028
+ '--name=[Name of the resource]:name' \\
15029
+ '--module=[Module name]:module:_ooneex_modules'
14916
15030
  ;;
14917
15031
  make:controller)
14918
15032
  _arguments -s \\
@@ -14923,11 +15037,9 @@ _ooneex() {
14923
15037
  '--route-method=[Route HTTP method]:method:(GET POST PUT PATCH DELETE HEAD OPTIONS)' \\
14924
15038
  '--is-socket[Socket mode]'
14925
15039
  ;;
14926
- make:middleware)
15040
+ make:docker)
14927
15041
  _arguments -s \\
14928
- '--name=[Name of the resource]:name' \\
14929
- '--module=[Module name]:module:_ooneex_modules' \\
14930
- '--is-socket[Socket mode]'
15042
+ '--name=[Docker service name]:name:(clickhouse elasticsearch grafana jaeger keycloak libretranslate maildev memcached minio mongodb mysql nats postgres prometheus rabbitmq redis temporal vault)'
14931
15043
  ;;
14932
15044
  make:entity)
14933
15045
  _arguments -s \\
@@ -14935,6 +15047,12 @@ _ooneex() {
14935
15047
  '--module=[Module name]:module:_ooneex_modules' \\
14936
15048
  '--table-name=[Database table name]:table_name'
14937
15049
  ;;
15050
+ make:middleware)
15051
+ _arguments -s \\
15052
+ '--name=[Name of the resource]:name' \\
15053
+ '--module=[Module name]:module:_ooneex_modules' \\
15054
+ '--is-socket[Socket mode]'
15055
+ ;;
14938
15056
  make:pubsub)
14939
15057
  _arguments -s \\
14940
15058
  '--name=[Name of the resource]:name' \\
@@ -14945,65 +15063,28 @@ _ooneex() {
14945
15063
  _arguments -s \\
14946
15064
  '--module=[Module name]:module:_ooneex_modules'
14947
15065
  ;;
14948
- module:lock)
14949
- _arguments -s \\
14950
- '--module=[Module name]:module:_ooneex_modules' \\
14951
- '--override[Override already registered migrations]'
14952
- ;;
14953
- seed:create)
15066
+ migration:up|seed:run)
14954
15067
  _arguments -s \\
14955
- '--name=[Name of the resource]:name' \\
14956
- '--module=[Module name]:module:_ooneex_modules'
15068
+ '--drop[Drop the database before running]'
14957
15069
  ;;
14958
15070
  module:create)
14959
15071
  _arguments -s \\
14960
15072
  '--name=[Name of the resource]:name'
14961
15073
  ;;
14962
- module:remove)
14963
- _arguments -s \\
14964
- '--name=[Module name]:name:_ooneex_modules'
14965
- ;;
14966
- make:docker)
14967
- _arguments -s \\
14968
- '--name=[Docker service name]:name:(clickhouse elasticsearch grafana jaeger keycloak libretranslate maildev memcached minio mongodb mysql nats postgres prometheus rabbitmq redis temporal vault)'
14969
- ;;
14970
- app:create)
15074
+ module:lock)
14971
15075
  _arguments -s \\
14972
- '--name=[Name of the resource]:name' \\
14973
- '--destination=[Destination path]:destination:_files -/'
15076
+ '--module=[Module name]:module:_ooneex_modules' \\
15077
+ '--override[Override already registered migrations]'
14974
15078
  ;;
14975
- app:init)
15079
+ module:remove)
14976
15080
  _arguments -s \\
14977
- '--name=[Name of the resource]:name' \\
14978
- '--destination=[Destination path]:destination:_files -/' \\
14979
- '--app-type=[Application type]:type:(cli api)'
15081
+ '--name=[Module name]:name:_ooneex_modules'
14980
15082
  ;;
14981
- make:ai|make:analytics|make:cache|make:command|make:cron|make:database|make:logger|make:mailer|make:permission|make:repository|make:service|make:storage|make:vector-database)
15083
+ seed:create)
14982
15084
  _arguments -s \\
14983
15085
  '--name=[Name of the resource]:name' \\
14984
15086
  '--module=[Module name]:module:_ooneex_modules'
14985
15087
  ;;
14986
- issue:create)
14987
- _arguments -s \\
14988
- '--title=[Issue title]:title' \\
14989
- '--state=[Issue state]:state:(Backlog Todo "In Progress" "In Review" Done Cancelled)' \\
14990
- '--priority=[Issue priority]:priority:(Low Medium High Urgent)' \\
14991
- '--description=[Issue description]:description' \\
14992
- '*--labels=[Label (repeatable)]:label' \\
14993
- '--module=[Module name]:module:_ooneex_modules' \\
14994
- '--interactive[Prompt for all fields]'
14995
- ;;
14996
- issue:pull)
14997
- _arguments -s \\
14998
- '--id=[Linear issue ID or identifier]:id' \\
14999
- '--module=[Module name]:module:_ooneex_modules'
15000
- ;;
15001
- migration:up|seed:run)
15002
- _arguments -s \\
15003
- '--drop[Drop the database before running]'
15004
- ;;
15005
- app:build|app:start|app:stop|help|make:release|make:resource:book|claude:skill:create|completion:zsh)
15006
- ;;
15007
15088
  esac
15008
15089
  ;;
15009
15090
  esac
@@ -100248,4 +100329,4 @@ SeedRunCommand = __legacyDecorateClassTS([
100248
100329
  // src/index.ts
100249
100330
  await run();
100250
100331
 
100251
- //# debugId=C0A94E3D0B33D65A64756E2164756E21
100332
+ //# debugId=5D565F8BCFA6DAC564756E2164756E21