cmdx 1.13.0 → 1.15.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 (154) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +92 -76
  3. data/LICENSE.txt +3 -20
  4. data/README.md +16 -8
  5. data/lib/cmdx/attribute.rb +42 -5
  6. data/lib/cmdx/context.rb +16 -0
  7. data/lib/cmdx/executor.rb +9 -9
  8. data/lib/cmdx/result.rb +27 -7
  9. data/lib/cmdx/task.rb +19 -0
  10. data/lib/cmdx/validator_registry.rb +1 -0
  11. data/lib/cmdx/validators/absence.rb +61 -0
  12. data/lib/cmdx/version.rb +1 -1
  13. data/lib/locales/af.yml +1 -0
  14. data/lib/locales/ar.yml +1 -0
  15. data/lib/locales/az.yml +1 -0
  16. data/lib/locales/be.yml +1 -0
  17. data/lib/locales/bg.yml +1 -0
  18. data/lib/locales/bn.yml +1 -0
  19. data/lib/locales/bs.yml +1 -0
  20. data/lib/locales/ca.yml +1 -0
  21. data/lib/locales/cnr.yml +1 -0
  22. data/lib/locales/cs.yml +1 -0
  23. data/lib/locales/cy.yml +1 -0
  24. data/lib/locales/da.yml +1 -0
  25. data/lib/locales/de.yml +1 -0
  26. data/lib/locales/dz.yml +1 -0
  27. data/lib/locales/el.yml +1 -0
  28. data/lib/locales/en.yml +1 -0
  29. data/lib/locales/eo.yml +1 -0
  30. data/lib/locales/es.yml +1 -0
  31. data/lib/locales/et.yml +1 -0
  32. data/lib/locales/eu.yml +1 -0
  33. data/lib/locales/fa.yml +1 -0
  34. data/lib/locales/fi.yml +1 -0
  35. data/lib/locales/fr.yml +1 -0
  36. data/lib/locales/fy.yml +1 -0
  37. data/lib/locales/gd.yml +1 -0
  38. data/lib/locales/gl.yml +1 -0
  39. data/lib/locales/he.yml +1 -0
  40. data/lib/locales/hi.yml +1 -0
  41. data/lib/locales/hr.yml +1 -0
  42. data/lib/locales/hu.yml +1 -0
  43. data/lib/locales/hy.yml +1 -0
  44. data/lib/locales/id.yml +1 -0
  45. data/lib/locales/is.yml +1 -0
  46. data/lib/locales/it.yml +1 -0
  47. data/lib/locales/ja.yml +1 -0
  48. data/lib/locales/ka.yml +1 -0
  49. data/lib/locales/kk.yml +1 -0
  50. data/lib/locales/km.yml +1 -0
  51. data/lib/locales/kn.yml +1 -0
  52. data/lib/locales/ko.yml +1 -0
  53. data/lib/locales/lb.yml +1 -0
  54. data/lib/locales/lo.yml +1 -0
  55. data/lib/locales/lt.yml +1 -0
  56. data/lib/locales/lv.yml +1 -0
  57. data/lib/locales/mg.yml +1 -0
  58. data/lib/locales/mk.yml +1 -0
  59. data/lib/locales/ml.yml +1 -0
  60. data/lib/locales/mn.yml +1 -0
  61. data/lib/locales/mr-IN.yml +1 -0
  62. data/lib/locales/ms.yml +1 -0
  63. data/lib/locales/nb.yml +1 -0
  64. data/lib/locales/ne.yml +1 -0
  65. data/lib/locales/nl.yml +1 -0
  66. data/lib/locales/nn.yml +1 -0
  67. data/lib/locales/oc.yml +1 -0
  68. data/lib/locales/or.yml +1 -0
  69. data/lib/locales/pa.yml +1 -0
  70. data/lib/locales/pl.yml +1 -0
  71. data/lib/locales/pt.yml +1 -0
  72. data/lib/locales/rm.yml +1 -0
  73. data/lib/locales/ro.yml +1 -0
  74. data/lib/locales/ru.yml +1 -0
  75. data/lib/locales/sc.yml +1 -0
  76. data/lib/locales/sk.yml +1 -0
  77. data/lib/locales/sl.yml +1 -0
  78. data/lib/locales/sq.yml +1 -0
  79. data/lib/locales/sr.yml +1 -0
  80. data/lib/locales/st.yml +1 -0
  81. data/lib/locales/sv.yml +1 -0
  82. data/lib/locales/sw.yml +1 -0
  83. data/lib/locales/ta.yml +1 -0
  84. data/lib/locales/te.yml +1 -0
  85. data/lib/locales/th.yml +1 -0
  86. data/lib/locales/tl.yml +1 -0
  87. data/lib/locales/tr.yml +1 -0
  88. data/lib/locales/tt.yml +1 -0
  89. data/lib/locales/ug.yml +1 -0
  90. data/lib/locales/uk.yml +1 -0
  91. data/lib/locales/ur.yml +1 -0
  92. data/lib/locales/uz.yml +1 -0
  93. data/lib/locales/vi.yml +1 -0
  94. data/lib/locales/wo.yml +1 -0
  95. data/lib/locales/zh-CN.yml +1 -0
  96. data/lib/locales/zh-HK.yml +1 -0
  97. data/lib/locales/zh-TW.yml +1 -0
  98. data/lib/locales/zh-YUE.yml +1 -0
  99. data/mkdocs.yml +65 -36
  100. metadata +4 -57
  101. data/.cursor/prompts/docs.md +0 -12
  102. data/.cursor/prompts/llms.md +0 -8
  103. data/.cursor/prompts/rspec.md +0 -24
  104. data/.cursor/prompts/yardoc.md +0 -15
  105. data/.cursor/rules/cursor-instructions.mdc +0 -68
  106. data/.irbrc +0 -18
  107. data/.rspec +0 -4
  108. data/.rubocop.yml +0 -95
  109. data/.ruby-version +0 -1
  110. data/.yard-lint.yml +0 -174
  111. data/.yardopts +0 -7
  112. data/docs/.DS_Store +0 -0
  113. data/docs/assets/favicon.ico +0 -0
  114. data/docs/assets/favicon.svg +0 -1
  115. data/docs/attributes/coercions.md +0 -155
  116. data/docs/attributes/defaults.md +0 -77
  117. data/docs/attributes/definitions.md +0 -283
  118. data/docs/attributes/naming.md +0 -68
  119. data/docs/attributes/transformations.md +0 -63
  120. data/docs/attributes/validations.md +0 -336
  121. data/docs/basics/chain.md +0 -108
  122. data/docs/basics/context.md +0 -121
  123. data/docs/basics/execution.md +0 -152
  124. data/docs/basics/setup.md +0 -107
  125. data/docs/callbacks.md +0 -157
  126. data/docs/configuration.md +0 -314
  127. data/docs/deprecation.md +0 -143
  128. data/docs/getting_started.md +0 -137
  129. data/docs/index.md +0 -134
  130. data/docs/internationalization.md +0 -126
  131. data/docs/interruptions/exceptions.md +0 -52
  132. data/docs/interruptions/faults.md +0 -169
  133. data/docs/interruptions/halt.md +0 -216
  134. data/docs/logging.md +0 -90
  135. data/docs/middlewares.md +0 -191
  136. data/docs/outcomes/result.md +0 -197
  137. data/docs/outcomes/states.md +0 -66
  138. data/docs/outcomes/statuses.md +0 -65
  139. data/docs/retries.md +0 -121
  140. data/docs/stylesheets/extra.css +0 -42
  141. data/docs/tips_and_tricks.md +0 -157
  142. data/docs/workflows.md +0 -226
  143. data/examples/active_record_database_transaction.md +0 -27
  144. data/examples/active_record_query_tagging.md +0 -46
  145. data/examples/flipper_feature_flags.md +0 -50
  146. data/examples/paper_trail_whatdunnit.md +0 -39
  147. data/examples/redis_idempotency.md +0 -71
  148. data/examples/sentry_error_tracking.md +0 -46
  149. data/examples/sidekiq_async_execution.md +0 -29
  150. data/examples/stoplight_circuit_breaker.md +0 -36
  151. data/src/cmdx-dark-logo.png +0 -0
  152. data/src/cmdx-favicon.svg +0 -1
  153. data/src/cmdx-light-logo.png +0 -0
  154. data/src/cmdx-logo.svg +0 -1
data/lib/locales/ru.yml CHANGED
@@ -26,6 +26,7 @@ ru:
26
26
  symbol: "символ"
27
27
  time: "время"
28
28
  validators:
29
+ absence: "должен быть пустым"
29
30
  exclusion:
30
31
  of: "не должен быть одним из: %{values}"
31
32
  within: "не должен быть между %{min} и %{max}"
data/lib/locales/sc.yml CHANGED
@@ -26,6 +26,7 @@ sc:
26
26
  symbol: "sìmbulu"
27
27
  time: "ora"
28
28
  validators:
29
+ absence: "deve èssere bòidu"
29
30
  exclusion:
30
31
  of: "non deve èssere unu de: %{values}"
31
32
  within: "non deve èssere intre %{min} e %{max}"
data/lib/locales/sk.yml CHANGED
@@ -26,6 +26,7 @@ sk:
26
26
  symbol: "symbol"
27
27
  time: "čas"
28
28
  validators:
29
+ absence: "musí byť prázdne"
29
30
  exclusion:
30
31
  of: "nesmie byť jedným z: %{values}"
31
32
  within: "nesmie byť medzi %{min} a %{max}"
data/lib/locales/sl.yml CHANGED
@@ -26,6 +26,7 @@ sl:
26
26
  symbol: "simbol"
27
27
  time: "čas"
28
28
  validators:
29
+ absence: "mora biti prazno"
29
30
  exclusion:
30
31
  of: "ne sme biti eden od: %{values}"
31
32
  within: "ne sme biti med %{min} in %{max}"
data/lib/locales/sq.yml CHANGED
@@ -26,6 +26,7 @@ sq:
26
26
  symbol: "simbol"
27
27
  time: "koha"
28
28
  validators:
29
+ absence: "duhet të jetë bosh"
29
30
  exclusion:
30
31
  of: "nuk duhet të jetë një nga: %{values}"
31
32
  within: "nuk duhet të jetë mes %{min} dhe %{max}"
data/lib/locales/sr.yml CHANGED
@@ -26,6 +26,7 @@ sr:
26
26
  symbol: "симбол"
27
27
  time: "време"
28
28
  validators:
29
+ absence: "мора бити празно"
29
30
  exclusion:
30
31
  of: "не сме бити један од: %{values}"
31
32
  within: "не сме бити између %{min} и %{max}"
data/lib/locales/st.yml CHANGED
@@ -26,6 +26,7 @@ st:
26
26
  symbol: "mokhoa"
27
27
  time: "nako"
28
28
  validators:
29
+ absence: "e tlameha ho ba e se na letho"
29
30
  exclusion:
30
31
  of: "ha e tlameha ho ba e mong oa: %{values}"
31
32
  within: "ha e tlameha ho ba pakeng tsa %{min} le %{max}"
data/lib/locales/sv.yml CHANGED
@@ -26,6 +26,7 @@ sv:
26
26
  symbol: "symbol"
27
27
  time: "tid"
28
28
  validators:
29
+ absence: "måste vara tom"
29
30
  exclusion:
30
31
  of: "får inte vara en av: %{values}"
31
32
  within: "får inte vara mellan %{min} och %{max}"
data/lib/locales/sw.yml CHANGED
@@ -26,6 +26,7 @@ sw:
26
26
  symbol: "ishara"
27
27
  time: "wakati"
28
28
  validators:
29
+ absence: "lazima iwe tupu"
29
30
  exclusion:
30
31
  of: "haipaswi kuwa moja ya: %{values}"
31
32
  within: "haipaswi kuwa kati ya %{min} na %{max}"
data/lib/locales/ta.yml CHANGED
@@ -26,6 +26,7 @@ ta:
26
26
  symbol: "குறியீடு"
27
27
  time: "நேரம்"
28
28
  validators:
29
+ absence: "வெறுமையாக இருக்க வேண்டும்"
29
30
  exclusion:
30
31
  of: "பின்வருவனவற்றில் ஒன்றாக இருக்கக்கூடாது: %{values}"
31
32
  within: "%{min} மற்றும் %{max} இடையே இருக்கக்கூடாது"
data/lib/locales/te.yml CHANGED
@@ -26,6 +26,7 @@ te:
26
26
  symbol: "చిహ్నం"
27
27
  time: "సమయం"
28
28
  validators:
29
+ absence: "ఖాళీగా ఉండాలి"
29
30
  exclusion:
30
31
  of: "ఈ క్రింది వాటిలో ఒకటి కాకూడదు: %{values}"
31
32
  within: "%{min} మరియు %{max} మధ్య ఉండకూడదు"
data/lib/locales/th.yml CHANGED
@@ -26,6 +26,7 @@ th:
26
26
  symbol: "สัญลักษณ์"
27
27
  time: "เวลา"
28
28
  validators:
29
+ absence: "ต้องเป็นค่าว่าง"
29
30
  exclusion:
30
31
  of: "ต้องไม่ใช่หนึ่งใน: %{values}"
31
32
  within: "ต้องไม่อยู่ระหว่าง %{min} และ %{max}"
data/lib/locales/tl.yml CHANGED
@@ -26,6 +26,7 @@ tl:
26
26
  symbol: "symbol"
27
27
  time: "oras"
28
28
  validators:
29
+ absence: "dapat na walang laman"
29
30
  exclusion:
30
31
  of: "hindi dapat na isa sa: %{values}"
31
32
  within: "hindi dapat na nasa pagitan ng %{min} at %{max}"
data/lib/locales/tr.yml CHANGED
@@ -26,6 +26,7 @@ tr:
26
26
  symbol: "sembol"
27
27
  time: "zaman"
28
28
  validators:
29
+ absence: "boş olmalıdır"
29
30
  exclusion:
30
31
  of: "şunlardan biri olmamalıdır: %{values}"
31
32
  within: "%{min} ve %{max} arasında olmamalıdır"
data/lib/locales/tt.yml CHANGED
@@ -26,6 +26,7 @@ tt:
26
26
  symbol: "символ"
27
27
  time: "вакыт"
28
28
  validators:
29
+ absence: "буш булырга тиеш"
29
30
  exclusion:
30
31
  of: "боларның берсе булмасын: %{values}"
31
32
  within: "%{min} һәм %{max} арасында булмасын"
data/lib/locales/ug.yml CHANGED
@@ -26,6 +26,7 @@ ug:
26
26
  symbol: "بەلگە"
27
27
  time: "ۋاقىت"
28
28
  validators:
29
+ absence: "بوش بولۇشى كېرەك"
29
30
  exclusion:
30
31
  of: "بۇلارنىڭ بىرى بولماسلىقى كېرەك: %{values}"
31
32
  within: "%{min} ۋە %{max} ئارىسىدا بولماسلىقى كېرەك"
data/lib/locales/uk.yml CHANGED
@@ -26,6 +26,7 @@ uk:
26
26
  symbol: "символ"
27
27
  time: "час"
28
28
  validators:
29
+ absence: "має бути порожнім"
29
30
  exclusion:
30
31
  of: "не може бути одним з: %{values}"
31
32
  within: "не може бути між %{min} та %{max}"
data/lib/locales/ur.yml CHANGED
@@ -26,6 +26,7 @@ ur:
26
26
  symbol: "علامت"
27
27
  time: "وقت"
28
28
  validators:
29
+ absence: "خالی ہونا ضروری ہے"
29
30
  exclusion:
30
31
  of: "ان میں سے کوئی ایک نہیں ہونا چاہیے: %{values}"
31
32
  within: "%{min} اور %{max} کے درمیان نہیں ہونا چاہیے"
data/lib/locales/uz.yml CHANGED
@@ -26,6 +26,7 @@ uz:
26
26
  symbol: "belgi"
27
27
  time: "vaqt"
28
28
  validators:
29
+ absence: "bo'sh bo'lishi kerak"
29
30
  exclusion:
30
31
  of: "bularning biri bo'lmasligi kerak: %{values}"
31
32
  within: "%{min} va %{max} oralig'ida bo'lmasligi kerak"
data/lib/locales/vi.yml CHANGED
@@ -26,6 +26,7 @@ vi:
26
26
  symbol: "ký hiệu"
27
27
  time: "thời gian"
28
28
  validators:
29
+ absence: "phải để trống"
29
30
  exclusion:
30
31
  of: "không được là một trong: %{values}"
31
32
  within: "không được nằm giữa %{min} và %{max}"
data/lib/locales/wo.yml CHANGED
@@ -26,6 +26,7 @@ wo:
26
26
  symbol: "simbol"
27
27
  time: "jamono"
28
28
  validators:
29
+ absence: "dafa war a nekk lu nekk"
29
30
  exclusion:
30
31
  of: "duñu war a nekk benn ci: %{values}"
31
32
  within: "duñu war a nekk ci digg %{min} ak %{max}"
@@ -26,6 +26,7 @@ zh-CN:
26
26
  symbol: "符号"
27
27
  time: "时间"
28
28
  validators:
29
+ absence: "必须为空"
29
30
  exclusion:
30
31
  of: "不能是以下之一: %{values}"
31
32
  within: "不能在 %{min} 和 %{max} 之间"
@@ -26,6 +26,7 @@ zh-HK:
26
26
  symbol: "符號"
27
27
  time: "時間"
28
28
  validators:
29
+ absence: "必須是空白"
29
30
  exclusion:
30
31
  of: "不可以是其中一個:%{values}"
31
32
  within: "不可以在 %{min} 和 %{max} 之間"
@@ -26,6 +26,7 @@ zh-TW:
26
26
  symbol: "符號"
27
27
  time: "時間"
28
28
  validators:
29
+ absence: "必須是空白"
29
30
  exclusion:
30
31
  of: "不可以是其中一個:%{values}"
31
32
  within: "不可以在 %{min} 和 %{max} 之間"
@@ -26,6 +26,7 @@ zh-YUE:
26
26
  symbol: "符號"
27
27
  time: "時間"
28
28
  validators:
29
+ absence: "必須係空白"
29
30
  exclusion:
30
31
  of: "唔可以係其中一個:%{values}"
31
32
  within: "唔可以喺 %{min} 同 %{max} 之間"
data/mkdocs.yml CHANGED
@@ -54,6 +54,8 @@ theme:
54
54
  - navigation.expand
55
55
  - navigation.path
56
56
  - navigation.sections
57
+ - navigation.tabs
58
+ - navigation.tabs.sticky
57
59
  - navigation.top
58
60
  - navigation.tracking
59
61
  - search.highlight
@@ -81,9 +83,26 @@ markdown_extensions:
81
83
  - tables
82
84
  - toc:
83
85
  permalink: true
86
+ title: On this page
84
87
 
85
88
  plugins:
86
89
  - search
90
+ - rss:
91
+ match_path: blog/posts/.*
92
+ date_from_meta:
93
+ as_creation: date
94
+ categories:
95
+ - categories
96
+ - blog:
97
+ blog_dir: blog
98
+ blog_toc: true
99
+ post_date_format: long
100
+ post_url_format: "{slug}"
101
+ archive_date_format: MMMM yyyy
102
+ draft_if_future_date: true
103
+ categories_allowed:
104
+ - Tutorials
105
+ - Updates
87
106
  - llmstxt:
88
107
  markdown_description: >-
89
108
  CMDx is a Ruby framework for building maintainable, observable business logic through composable command/service objects.
@@ -124,51 +143,61 @@ plugins:
124
143
  - workflows.md: Composing multiple tasks into sequential pipelines with conditional execution
125
144
  More:
126
145
  - tips_and_tricks.md: Best practices, patterns, and techniques for maintainable CMDx applications
146
+ - comparison.md: Comparison with other command/service object frameworks
147
+ Ecosystem:
148
+ - cmdx-rspec: RSpec test matchers (https://github.com/drexed/cmdx-rspec)
127
149
 
128
150
  nav:
129
151
  - Home: index.md
130
- - Getting Started: getting_started.md
131
- - Configuration: configuration.md
132
- - Basics:
133
- - Setup: basics/setup.md
134
- - Execution: basics/execution.md
135
- - Context: basics/context.md
136
- - Chain: basics/chain.md
137
- - Interruptions:
138
- - Halt: interruptions/halt.md
139
- - Faults: interruptions/faults.md
140
- - Exceptions: interruptions/exceptions.md
141
- - Outcomes:
142
- - Result: outcomes/result.md
143
- - States: outcomes/states.md
144
- - Statuses: outcomes/statuses.md
145
- - Attributes:
146
- - Definitions: attributes/definitions.md
147
- - Naming: attributes/naming.md
148
- - Coercions: attributes/coercions.md
149
- - Validations: attributes/validations.md
150
- - Defaults: attributes/defaults.md
151
- - Transformations: attributes/transformations.md
152
- - Features:
153
- - Callbacks: callbacks.md
154
- - Middlewares: middlewares.md
155
- - Logging: logging.md
156
- - Internationalization: internationalization.md
157
- - Retries: retries.md
158
- - Deprecation: deprecation.md
159
- - Workflows: workflows.md
160
- - More:
161
- - Tips and Tricks: tips_and_tricks.md
162
- - References:
163
- - API Documentation: https://drexed.github.io/cmdx/api/index.html
164
- - llms.txt: https://drexed.github.io/cmdx/llms.txt
165
- - llms-full.txt: https://drexed.github.io/cmdx/llms-full.txt
152
+ - Documentation:
153
+ - Getting Started: getting_started.md
154
+ - Configuration: configuration.md
155
+ - Basics:
156
+ - Setup: basics/setup.md
157
+ - Execution: basics/execution.md
158
+ - Context: basics/context.md
159
+ - Chain: basics/chain.md
160
+ - Interruptions:
161
+ - Halt: interruptions/halt.md
162
+ - Faults: interruptions/faults.md
163
+ - Exceptions: interruptions/exceptions.md
164
+ - Outcomes:
165
+ - Result: outcomes/result.md
166
+ - States: outcomes/states.md
167
+ - Statuses: outcomes/statuses.md
168
+ - Attributes:
169
+ - Definitions: attributes/definitions.md
170
+ - Naming: attributes/naming.md
171
+ - Coercions: attributes/coercions.md
172
+ - Validations: attributes/validations.md
173
+ - Defaults: attributes/defaults.md
174
+ - Transformations: attributes/transformations.md
175
+ - Features:
176
+ - Callbacks: callbacks.md
177
+ - Middlewares: middlewares.md
178
+ - Logging: logging.md
179
+ - Internationalization: internationalization.md
180
+ - Retries: retries.md
181
+ - Deprecation: deprecation.md
182
+ - Workflows: workflows.md
183
+ - More:
184
+ - Tips and Tricks: tips_and_tricks.md
185
+ - Comparison: comparison.md
186
+ - References:
187
+ - API Documentation: https://drexed.github.io/cmdx/api/index.html
188
+ - llms.txt: https://drexed.github.io/cmdx/llms.txt
189
+ - llms-full.txt: https://drexed.github.io/cmdx/llms-full.txt
190
+ - Ecosystem:
191
+ - cmdx-rspec: https://github.com/drexed/cmdx-rspec
192
+ - Blog: blog/index.md
166
193
 
167
194
  extra:
168
195
  generator: false
169
196
  social:
170
197
  - icon: fontawesome/brands/github
171
198
  link: https://github.com/drexed/cmdx
199
+ - icon: fontawesome/solid/rss
200
+ link: https://drexed.github.io/cmdx/feed_rss_created.xml
172
201
 
173
202
  extra_css:
174
203
  - stylesheets/extra.css
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cmdx
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.13.0
4
+ version: 1.15.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juan Gomez
@@ -227,61 +227,11 @@ extensions: []
227
227
  extra_rdoc_files: []
228
228
  files:
229
229
  - ".DS_Store"
230
- - ".cursor/prompts/docs.md"
231
- - ".cursor/prompts/llms.md"
232
- - ".cursor/prompts/rspec.md"
233
- - ".cursor/prompts/yardoc.md"
234
- - ".cursor/rules/cursor-instructions.mdc"
235
- - ".irbrc"
236
- - ".rspec"
237
- - ".rubocop.yml"
238
- - ".ruby-version"
239
- - ".yard-lint.yml"
240
- - ".yardopts"
241
230
  - CHANGELOG.md
242
231
  - CODE_OF_CONDUCT.md
243
232
  - LICENSE.txt
244
233
  - README.md
245
234
  - Rakefile
246
- - docs/.DS_Store
247
- - docs/assets/favicon.ico
248
- - docs/assets/favicon.svg
249
- - docs/attributes/coercions.md
250
- - docs/attributes/defaults.md
251
- - docs/attributes/definitions.md
252
- - docs/attributes/naming.md
253
- - docs/attributes/transformations.md
254
- - docs/attributes/validations.md
255
- - docs/basics/chain.md
256
- - docs/basics/context.md
257
- - docs/basics/execution.md
258
- - docs/basics/setup.md
259
- - docs/callbacks.md
260
- - docs/configuration.md
261
- - docs/deprecation.md
262
- - docs/getting_started.md
263
- - docs/index.md
264
- - docs/internationalization.md
265
- - docs/interruptions/exceptions.md
266
- - docs/interruptions/faults.md
267
- - docs/interruptions/halt.md
268
- - docs/logging.md
269
- - docs/middlewares.md
270
- - docs/outcomes/result.md
271
- - docs/outcomes/states.md
272
- - docs/outcomes/statuses.md
273
- - docs/retries.md
274
- - docs/stylesheets/extra.css
275
- - docs/tips_and_tricks.md
276
- - docs/workflows.md
277
- - examples/active_record_database_transaction.md
278
- - examples/active_record_query_tagging.md
279
- - examples/flipper_feature_flags.md
280
- - examples/paper_trail_whatdunnit.md
281
- - examples/redis_idempotency.md
282
- - examples/sentry_error_tracking.md
283
- - examples/sidekiq_async_execution.md
284
- - examples/stoplight_circuit_breaker.md
285
235
  - lib/cmdx.rb
286
236
  - lib/cmdx/.DS_Store
287
237
  - lib/cmdx/attribute.rb
@@ -329,6 +279,7 @@ files:
329
279
  - lib/cmdx/utils/condition.rb
330
280
  - lib/cmdx/utils/format.rb
331
281
  - lib/cmdx/validator_registry.rb
282
+ - lib/cmdx/validators/absence.rb
332
283
  - lib/cmdx/validators/exclusion.rb
333
284
  - lib/cmdx/validators/format.rb
334
285
  - lib/cmdx/validators/inclusion.rb
@@ -431,13 +382,9 @@ files:
431
382
  - lib/locales/zh-TW.yml
432
383
  - lib/locales/zh-YUE.yml
433
384
  - mkdocs.yml
434
- - src/cmdx-dark-logo.png
435
- - src/cmdx-favicon.svg
436
- - src/cmdx-light-logo.png
437
- - src/cmdx-logo.svg
438
385
  homepage: https://github.com/drexed/cmdx
439
386
  licenses:
440
- - MIT
387
+ - LGPL-3.0
441
388
  metadata:
442
389
  homepage_uri: https://github.com/drexed/cmdx
443
390
  source_code_uri: https://github.com/drexed/cmdx
@@ -459,7 +406,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
459
406
  - !ruby/object:Gem::Version
460
407
  version: '0'
461
408
  requirements: []
462
- rubygems_version: 3.7.2
409
+ rubygems_version: 4.0.3
463
410
  specification_version: 4
464
411
  summary: CMDx is a framework for building maintainable business processes.
465
412
  test_files: []
@@ -1,12 +0,0 @@
1
- You are a senior Ruby developer with expert knowledge of CMDx and writing documentation.
2
-
3
- Update the active tab using the following guidelines:
4
-
5
- - Follow best practices and implementation
6
- - Use a consistent warm, friendly and professional voice
7
- - Examples should be concise, non-repetitive, and realistic
8
- - Update any pre-existing documentation to match stated rules
9
- - Examples should not cross boundaries or focus
10
- - Docs must cover both typical use cases, including invalid and error conditions
11
- - Use mkdocs Admonitions to emphasize critical information (https://squidfunk.github.io/mkdocs-material/reference/admonitions/)
12
- - Optimize for LLM's including coding and AI agents
@@ -1,8 +0,0 @@
1
- Process the following instructions in the order given:
2
-
3
- 1. Create an `LLM.md` file
4
- 2. Append all files within `docs/**/*.md` into @LLM.md
5
- 2a. Use order outlined under the nav key in @mkdocs.yml
6
- 2b. Process one file at a time faster performance and improved accuracy
7
- 2c. Exclude @index.md and @LLM.md files
8
- 2d. All URLs should be absolute
@@ -1,24 +0,0 @@
1
- You are a senior Ruby developer with expert knowledge of RSpec.
2
-
3
- Add tests for the active tab using the following guidelines:
4
-
5
- - Expectations should be concise, non-repetitive, and realistic (how it would be used in the real world)
6
- - Follow best practices and implementation
7
- - Update any pre-existing specs to match stated rules
8
- - New tests should be consistent with current `spec/cmdx` specs
9
- - Use custom matchers available within `lib/cmdx/rspec`
10
- - Use task helpers available within `spec/support/helpers`
11
- - Use stubs to return predefined values for specific methods. Isolate the unit being tested, but avoid over-mocking; test real behavior when possible (mocks should be used only when necessary)
12
- - Ensure each test is independent; avoid shared state between tests
13
- - Use let and let! to define test data, ensuring minimal and necessary setup
14
- - Context block descriptions should start with the following words: `when`, `with`, `without`
15
- - Organize tests logically using describe for classes/modules and context for different scenarios
16
- - Use subject to define the object under test when appropriate to avoid repetition
17
- - Ensure test file paths mirror the structure of the files being tested, but within the spec directory (e.g., lib/cmdx/task.rb → spec/cmdx/task_spec.rb)
18
- - Use clear and descriptive names for describe, context, and it blocks
19
- - Prefer the expect syntax for assertions to improve readability
20
- - Keep test code concise; avoid unnecessary complexity or duplication
21
- - Tests must cover both typical cases and edge cases, including Invalid and error conditions
22
- - Consider all possible scenarios for each method or behavior and ensure they are tested
23
- - Do NOT include integration or real world examples
24
- - Verify all specs are passing
@@ -1,15 +0,0 @@
1
- You are a senior Ruby developer with expert knowledge of YARDoc.
2
-
3
- Add yardoc to the active tab using the following guidelines:
4
-
5
- - Follow best practices and implementation
6
- - New documentation should be consistent with current `lib/cmdx` documentation
7
- - Examples should be concise, non-repetitive, and realistic
8
- - Avoid unnecessary complexity or duplication
9
- - Update any pre-existing documentation to match stated rules
10
- - Do NOT include `CMDx` module level docs
11
- - Module level docs description should NOT include `@example`
12
- - Method level docs should include `@example`, `param`, `@options`, `@return`, and any `@raise`
13
- - Hash `@params` should expand with possible `@option`
14
- - Module and method level docs should NOT include `@since`
15
- - Add RBS inline comments after YARDoc block
@@ -1,68 +0,0 @@
1
- ---
2
- description:
3
- globs:
4
- alwaysApply: true
5
- ---
6
-
7
- # Ruby Coding Standards
8
-
9
- Follow the official Ruby gem guides for best practices.
10
- Reference the guides outlined in https://guides.rubygems.org
11
-
12
- ## Project Context
13
- CMDx provides a framework for designing and executing complex business logic within service/command objects.
14
- Reference the CMDx documentation in https://github.com/drexed/cmdx/blob/main/LLM.md
15
-
16
- ## Technology Stack
17
- - Ruby 3.4+
18
- - RSpec 3.1+
19
-
20
- ## Development Guidelines
21
- - Performance is critical - benchmark any changes that could affect speed
22
- - Follow existing code patterns and conventions
23
- - Maintain backward compatibility for public API
24
-
25
- ## Code Style and Structure
26
- - Write concise, idiomatic Ruby code with accurate examples
27
- - Follow Ruby conventions and best practices
28
- - Use object-oriented and functional programming patterns as appropriate
29
- - Prefer iteration and modularization over code duplication
30
- - Use descriptive variable and method names (e.g., user_signed_in?, calculate_total)
31
- - Write comprehensive code documentation using the Yardoc format
32
- - Minimize object allocations in hot paths
33
-
34
- ## Naming Conventions
35
- - Use snake_case for file names, method names, and variables
36
- - Use CamelCase for class and module names
37
-
38
- ## Syntax and Formatting
39
- - Follow the Ruby Style Guide (https://rubystyle.guide/)
40
- - Follow Ruby style conventions (2-space indentation, snake_case methods)
41
- - Use Ruby's expressive syntax (e.g., unless, ||=, &.)
42
- - Prefer double quotes for strings
43
- - Respect my Rubocop options
44
- - Run `bundle exec rubocop .` before finalizing any code changes
45
-
46
- ## Performance Optimization
47
- - Use memoization for expensive operations
48
-
49
- ## Testing
50
- - Follow the RSpec Style Guide (https://rspec.rubystyle.guide/)
51
- - Write comprehensive tests using RSpec
52
- - It's ok to put multiple assertions in the same example
53
- - Include both BDD and TDD based tests
54
- - Create test objects to share across tests
55
- - Do NOT make tests for obvious or reflective expectations
56
- - Prefer real objects over mocks. Use `instance_double` if necessary; never `double`
57
- - Don't test declarative configuration
58
- - Use appropriate matchers
59
- - Update tests and update Yardocs after you write code
60
- - Run `bundle rspec .` before finalizing any code changes
61
-
62
- ## Documentation
63
- - Utilize the YARDoc format when documenting Ruby code
64
- - Follow these best practices:
65
- - Avoid redundant comments that merely restate the code
66
- - Keep comments up-to-date with code changes
67
- - Keep documentation consistent
68
- - Update CHANGELOG.md with any changes
data/.irbrc DELETED
@@ -1,18 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require "pp"
4
-
5
- # rubocop:disable Style/MixinUsage
6
- unless defined?(CMDx)
7
- require_relative "lib/cmdx"
8
-
9
- require_relative "spec/support/helpers/task_builders"
10
- require_relative "spec/support/helpers/workflow_builders"
11
- include CMDx::Testing::TaskBuilders
12
- include CMDx::Testing::WorkflowBuilders
13
- end
14
- # rubocop:enable Style/MixinUsage
15
-
16
- def reload!
17
- exec("irb")
18
- end
data/.rspec DELETED
@@ -1,4 +0,0 @@
1
- --backtrace
2
- --color
3
- --format progress
4
- --order random