@futdevpro/dynamo-eslint 1.15.6 โ†’ 1.15.8

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 (119) hide show
  1. package/.cursor/rules/_ag_frontend-structure.mdc +5 -5
  2. package/.dynamo/version-bump.config.json +5 -0
  3. package/.github/workflows/main.yml +424 -395
  4. package/.husky/pre-commit +1 -0
  5. package/__documentations/2026-04-18-ccap-review-integration.md +173 -0
  6. package/build/configs/base.js +20 -1
  7. package/build/configs/base.js.map +1 -1
  8. package/build/configs/ngx.js +10 -0
  9. package/build/configs/ngx.js.map +1 -1
  10. package/build/plugin/index.d.ts +21 -0
  11. package/build/plugin/index.d.ts.map +1 -1
  12. package/build/plugin/index.js +38 -0
  13. package/build/plugin/index.js.map +1 -1
  14. package/build/plugin/rules/angular/angular-for-track-logic.d.ts +8 -0
  15. package/build/plugin/rules/angular/angular-for-track-logic.d.ts.map +1 -0
  16. package/build/plugin/rules/angular/angular-for-track-logic.js +82 -0
  17. package/build/plugin/rules/angular/angular-for-track-logic.js.map +1 -0
  18. package/build/plugin/rules/angular/effect-signal-loop.d.ts +10 -0
  19. package/build/plugin/rules/angular/effect-signal-loop.d.ts.map +1 -0
  20. package/build/plugin/rules/angular/effect-signal-loop.js +113 -0
  21. package/build/plugin/rules/angular/effect-signal-loop.js.map +1 -0
  22. package/build/plugin/rules/angular/no-async-ngoninit.d.ts +9 -0
  23. package/build/plugin/rules/angular/no-async-ngoninit.d.ts.map +1 -0
  24. package/build/plugin/rules/angular/no-async-ngoninit.js +43 -0
  25. package/build/plugin/rules/angular/no-async-ngoninit.js.map +1 -0
  26. package/build/plugin/rules/angular/no-component-direct-api.d.ts +10 -0
  27. package/build/plugin/rules/angular/no-component-direct-api.d.ts.map +1 -0
  28. package/build/plugin/rules/angular/no-component-direct-api.js +76 -0
  29. package/build/plugin/rules/angular/no-component-direct-api.js.map +1 -0
  30. package/build/plugin/rules/angular/no-method-call-in-template.d.ts +9 -0
  31. package/build/plugin/rules/angular/no-method-call-in-template.d.ts.map +1 -0
  32. package/build/plugin/rules/angular/no-method-call-in-template.js +80 -0
  33. package/build/plugin/rules/angular/no-method-call-in-template.js.map +1 -0
  34. package/build/plugin/rules/angular/no-ngfor-directive.d.ts +8 -0
  35. package/build/plugin/rules/angular/no-ngfor-directive.d.ts.map +1 -0
  36. package/build/plugin/rules/angular/no-ngfor-directive.js +60 -0
  37. package/build/plugin/rules/angular/no-ngfor-directive.js.map +1 -0
  38. package/build/plugin/rules/angular/no-ngif-directive.d.ts +8 -0
  39. package/build/plugin/rules/angular/no-ngif-directive.d.ts.map +1 -0
  40. package/build/plugin/rules/angular/no-ngif-directive.js +60 -0
  41. package/build/plugin/rules/angular/no-ngif-directive.js.map +1 -0
  42. package/build/plugin/rules/naming-patterns.d.ts +4 -0
  43. package/build/plugin/rules/naming-patterns.d.ts.map +1 -1
  44. package/build/plugin/rules/naming-patterns.js +331 -8
  45. package/build/plugin/rules/naming-patterns.js.map +1 -1
  46. package/build/plugin/rules/no-getter-logic.d.ts.map +1 -1
  47. package/build/plugin/rules/no-getter-logic.js +21 -2
  48. package/build/plugin/rules/no-getter-logic.js.map +1 -1
  49. package/build/plugin/rules/require-jsdoc-description.d.ts.map +1 -1
  50. package/build/plugin/rules/require-jsdoc-description.js +17 -0
  51. package/build/plugin/rules/require-jsdoc-description.js.map +1 -1
  52. package/build/plugin/rules/ts/data-model-extends.d.ts +9 -0
  53. package/build/plugin/rules/ts/data-model-extends.d.ts.map +1 -0
  54. package/build/plugin/rules/ts/data-model-extends.js +95 -0
  55. package/build/plugin/rules/ts/data-model-extends.js.map +1 -0
  56. package/build/plugin/rules/ts/no-any-type.d.ts +9 -0
  57. package/build/plugin/rules/ts/no-any-type.d.ts.map +1 -0
  58. package/build/plugin/rules/ts/no-any-type.js +37 -0
  59. package/build/plugin/rules/ts/no-any-type.js.map +1 -0
  60. package/build/plugin/rules/ts/no-as-cast.d.ts +9 -0
  61. package/build/plugin/rules/ts/no-as-cast.d.ts.map +1 -0
  62. package/build/plugin/rules/ts/no-as-cast.js +50 -0
  63. package/build/plugin/rules/ts/no-as-cast.js.map +1 -0
  64. package/build/plugin/rules/ts/no-dynamic-imports.d.ts +9 -0
  65. package/build/plugin/rules/ts/no-dynamic-imports.d.ts.map +1 -0
  66. package/build/plugin/rules/ts/no-dynamic-imports.js +51 -0
  67. package/build/plugin/rules/ts/no-dynamic-imports.js.map +1 -0
  68. package/build/plugin/rules/ts/no-native-browser-dialogs.d.ts +9 -0
  69. package/build/plugin/rules/ts/no-native-browser-dialogs.d.ts.map +1 -0
  70. package/build/plugin/rules/ts/no-native-browser-dialogs.js +79 -0
  71. package/build/plugin/rules/ts/no-native-browser-dialogs.js.map +1 -0
  72. package/build/plugin/rules/ts/no-plain-function-export.d.ts +10 -0
  73. package/build/plugin/rules/ts/no-plain-function-export.d.ts.map +1 -0
  74. package/build/plugin/rules/ts/no-plain-function-export.js +70 -0
  75. package/build/plugin/rules/ts/no-plain-function-export.js.map +1 -0
  76. package/build/plugin/rules/ts/one-export-per-file.d.ts +9 -0
  77. package/build/plugin/rules/ts/one-export-per-file.d.ts.map +1 -0
  78. package/build/plugin/rules/ts/one-export-per-file.js +74 -0
  79. package/build/plugin/rules/ts/one-export-per-file.js.map +1 -0
  80. package/package.json +6 -9
  81. package/pipeline.cicd.config.json +152 -0
  82. package/src/configs/base.ts +21 -1
  83. package/src/configs/ngx.ts +12 -0
  84. package/src/plugin/index.ts +44 -3
  85. package/src/plugin/rules/angular/angular-for-track-logic.spec.ts +44 -0
  86. package/src/plugin/rules/angular/angular-for-track-logic.ts +88 -0
  87. package/src/plugin/rules/angular/effect-signal-loop.spec.ts +89 -0
  88. package/src/plugin/rules/angular/effect-signal-loop.ts +125 -0
  89. package/src/plugin/rules/angular/no-async-ngoninit.spec.ts +50 -0
  90. package/src/plugin/rules/angular/no-async-ngoninit.ts +43 -0
  91. package/src/plugin/rules/angular/no-component-direct-api.spec.ts +78 -0
  92. package/src/plugin/rules/angular/no-component-direct-api.ts +82 -0
  93. package/src/plugin/rules/angular/no-method-call-in-template.spec.ts +63 -0
  94. package/src/plugin/rules/angular/no-method-call-in-template.ts +89 -0
  95. package/src/plugin/rules/angular/no-ngfor-directive.spec.ts +44 -0
  96. package/src/plugin/rules/angular/no-ngfor-directive.ts +62 -0
  97. package/src/plugin/rules/angular/no-ngif-directive.spec.ts +44 -0
  98. package/src/plugin/rules/angular/no-ngif-directive.ts +62 -0
  99. package/src/plugin/rules/naming-patterns.spec.ts +108 -22
  100. package/src/plugin/rules/naming-patterns.ts +390 -11
  101. package/src/plugin/rules/no-getter-logic.spec.ts +71 -0
  102. package/src/plugin/rules/no-getter-logic.ts +21 -2
  103. package/src/plugin/rules/require-jsdoc-description.spec.ts +1 -0
  104. package/src/plugin/rules/require-jsdoc-description.ts +19 -0
  105. package/src/plugin/rules/ts/data-model-extends.spec.ts +84 -0
  106. package/src/plugin/rules/ts/data-model-extends.ts +100 -0
  107. package/src/plugin/rules/ts/no-any-type.spec.ts +28 -0
  108. package/src/plugin/rules/ts/no-any-type.ts +36 -0
  109. package/src/plugin/rules/ts/no-as-cast.spec.ts +51 -0
  110. package/src/plugin/rules/ts/no-as-cast.ts +51 -0
  111. package/src/plugin/rules/ts/no-dynamic-imports.spec.ts +54 -0
  112. package/src/plugin/rules/ts/no-dynamic-imports.ts +49 -0
  113. package/src/plugin/rules/ts/no-native-browser-dialogs.spec.ts +54 -0
  114. package/src/plugin/rules/ts/no-native-browser-dialogs.ts +84 -0
  115. package/src/plugin/rules/ts/no-plain-function-export.spec.ts +72 -0
  116. package/src/plugin/rules/ts/no-plain-function-export.ts +73 -0
  117. package/src/plugin/rules/ts/one-export-per-file.spec.ts +64 -0
  118. package/src/plugin/rules/ts/one-export-per-file.ts +77 -0
  119. package/futdevpro-dynamo-eslint-1.15.6.tgz +0 -0
@@ -1,401 +1,430 @@
1
- name: Test and Deploy
2
- on:
3
- push:
4
- branches:
5
- - '**'
6
- permissions:
7
- actions: read
8
- id-token: write
9
- contents: read
10
- checks: write
11
- issues: read
12
- pull-requests: write
13
- env:
14
- PACKAGE_NAME: ''
15
- THIS_VERSION: 0.0.0
16
- LATEST_VERSION: 0.0.0
17
- VERSION_PUBLISHED: true
18
-
19
-
1
+ # =============================================================================
2
+ # Dynamo-ESLint CI/CD โ€” Overseer Pipeline Trigger
3
+ # =============================================================================
4
+ # Ez a workflow CSAK egy webhook-ot kuld az Overseer-nek es AZONNAL kilep.
5
+ # A pipeline-t az Overseer FDP Runner-ek futtatjak (nem a GitHub Actions).
6
+ #
7
+ # A regi workflow-k a fajl vegen kommentben megtalalhatok (fallback).
8
+ # =============================================================================
9
+
10
+ name: Trigger Pipeline
11
+ on:
12
+ workflow_dispatch:
13
+ # Az org-szintu GitHub webhook kozvetlenul triggereli az Overseer-t.
14
+ # Ez a workflow csak manualis fallback (workflow_dispatch).
15
+
20
16
  jobs:
21
- notification0:
22
- name: ๐Ÿน Discord start Notification
17
+ trigger:
18
+ name: Overseer Trigger
23
19
  runs-on: ubuntu-latest
24
- #runs-on: plo-koon
25
- timeout-minutes: 20
26
- outputs:
27
- start: ${{ steps.mark_start.outputs.started }}
20
+ timeout-minutes: 1
28
21
  steps:
29
22
  - uses: actions/checkout@v4
30
- - id: mark_start
31
- run: echo "started=$(date +%s)" >> "$GITHUB_OUTPUT"
32
- - name: Send Discord start notification
33
- uses: futdevpro/fdp-github-actions/discord-start-notification@latest
34
- with:
35
- NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
36
- APPLICATION_NAME: "Dynamo-ESLint"
37
- APPLICATION_EMOJI: "๐Ÿ”ง"
38
- COMMIT_MESSAGE: ${{ github.event.head_commit.message }}
39
- EVENT_DATETIME: ${{ github.event.head_commit.timestamp }}
40
- DISCORD_WEBHOOK_ID: ${{ secrets.DISCORD_WEBHOOK_ID }}
41
- DISCORD_WEBHOOK_TOKEN: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
42
-
43
- notification0_fail_report:
44
- name: ๐Ÿ’ฃ Discord Start Notification Fail Report
45
- runs-on: ubuntu-latest
46
- #runs-on: plo-koon
47
- timeout-minutes: 20
48
- if: always() && needs.notification0.result == 'failure'
49
- needs: [notification0]
50
- steps:
51
- - name: send custom message with args
52
- uses: appleboy/discord-action@master
53
- with:
54
- webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
55
- webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
56
- message: |
57
- โŒโŒโŒ๐Ÿ”ง Failed to send Discord start notification for ${{ github.repository }}! [๐Ÿ”—](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }})
58
-
59
- check_secrets:
60
- name: ๐Ÿ” Check Required Secrets and Variables
61
- #runs-on: ubuntu-latest
62
- runs-on: plo-koon
63
- timeout-minutes: 20
64
- steps:
65
- - name: Check Required Secrets and Variables
66
- uses: futdevpro/fdp-github-actions/check-secrets-and-variables@latest
67
- with:
68
- NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
69
- ITEMS_TO_CHECK: |
70
- [
71
- {
72
- "valueName": "NPM_TOKEN",
73
- "value": "${{ secrets.NPM_TOKEN }}",
74
- "type": "SECRET"
75
- },
76
- {
77
- "valueName": "DISCORD_WEBHOOK_ID",
78
- "value": "${{ secrets.DISCORD_WEBHOOK_ID }}",
79
- "type": "SECRET"
80
- },
81
- {
82
- "valueName": "DISCORD_WEBHOOK_TOKEN",
83
- "value": "${{ secrets.DISCORD_WEBHOOK_TOKEN }}",
84
- "type": "SECRET"
85
- },
86
- {
87
- "valueName": "OVERSEER_SECRET_KEY",
88
- "value": "${{ secrets.OVERSEER_SECRET_KEY }}",
89
- "type": "SECRET"
90
- },
91
-
92
- {
93
- "valueName": "OVERSEER_URL",
94
- "value": "${{ vars.OVERSEER_URL }}",
95
- "type": "VARIABLE"
96
- }
97
- ]
98
-
99
- check_dev_leftovers:
100
- name: ๐Ÿ” Check Dev leftovers
101
- #runs-on: ubuntu-latest
102
- runs-on: plo-koon
103
- timeout-minutes: 20
104
- steps:
105
- - name: Checkout code
106
- uses: actions/checkout@v4
107
-
108
- - name: Install Node.js
109
- uses: actions/setup-node@v2
110
- with:
111
- node-version: '16'
112
-
113
- # TODO: Check build version (to ALL packages)
114
- - name: Check build folder
115
- run: |
116
- node -e "
117
- const buildFolder = './build/';
118
- const fs = require('fs');
119
-
120
- fs.readdir(buildFolder, (err, files) => {
121
- if (!files?.length) {
122
- console.error(
123
- 'FDPError: ./build folder is MISSING!' +
124
- '\nbuild the project locally before push!'
125
- );
126
- process.exit(1);
127
- }
128
-
129
- if (files.includes('dynamo-eslint')) {
130
- console.error(
131
- 'FDPError: ./build contains dynamo-eslint folder which means this is a local dev build!' +
132
- '\nrebuild the project locally before push!'
133
- );
134
- process.exit(1);
135
- }
136
- });
137
- "
138
-
139
- test:
140
- name: ๐Ÿงช Test Build
141
- runs-on: ubuntu-latest
142
- needs: [ check_dev_leftovers ]
143
- timeout-minutes: 20
144
- steps:
145
- - name: Checkout code
146
- uses: actions/checkout@v4
147
-
148
- - name: Set NPM RC
149
- run: |
150
- echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
151
-
152
- - name: Get safe-chain version
153
- run: |
154
- VERSION=$(curl -s https://api.github.com/repos/AikidoSec/safe-chain/releases/latest | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/' | sed 's/^v//')
155
- echo "SAFE_CHAIN_VERSION=$VERSION" >> $GITHUB_ENV
156
-
157
- - name: Install safe-chain
158
- run: |
159
- curl -fsSL https://raw.githubusercontent.com/AikidoSec/safe-chain/main/install-scripts/install-safe-chain.sh | sh -s -- --ci
160
-
161
- - name: Install pnpm
162
- run: |
163
- npm i -g pnpm
164
-
165
- - name: Install Packages
166
- run: |
167
- pnpm i --safe-chain-skip-minimum-package-age
168
-
169
- - name: Build
170
- run: |
171
- npx tsc
172
-
173
- - name: Install Jasmine
174
- run: |
175
- npm i -g jasmine
176
-
177
- - name: Test
178
- run: |
179
- jasmine
180
-
181
- - name: Test Pack
182
- run: |
183
- pnpm pack
184
23
 
185
-
186
- check_version:
187
- name: ๐Ÿ” Check Version
188
- needs: [ test ]
189
- #runs-on: ubuntu-latest
190
- runs-on: plo-koon
191
- timeout-minutes: 20
192
- outputs:
193
- version_published: ${{ steps.version_check_results.outputs.version_published }}
194
- steps:
195
- - name: Checkout code
196
- uses: actions/checkout@v4
197
-
198
- - name: Set Package Name
199
- run: |
200
- echo "PACKAGE_NAME=$(node -p -e "require('./package.json').name")" >> $GITHUB_ENV
201
-
202
- - name: Set RC
203
- run: |
204
- echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
205
-
206
- - name: Get This Version
207
- run: |
208
- RAW_THIS_VERSION=$(node -p -e "require('./package.json').version")
209
- # replace ALL: 'v0' with '', '01' with '1', '.0' with '.'
210
- RAW_THIS_VERSION=$(echo $RAW_THIS_VERSION | sed 's:v0::g' | sed 's:01:1:g' | sed -e 's:\.0:\.:g')
211
- echo "THIS_VERSION=$RAW_THIS_VERSION" >> $GITHUB_ENV
212
-
213
- - name: Get Latest Version
214
- run: |
215
- echo "LATEST_VERSION=$(npm view ${{ env.PACKAGE_NAME }} version)" >> $GITHUB_ENV
216
-
217
- - name: Check All Versions
218
- run: |
219
- ALL_VERSIONS=$(npm view ${{ env.PACKAGE_NAME }} versions)
220
- if echo "$ALL_VERSIONS" | grep -q "${{ env.THIS_VERSION }}"; then
221
- echo "VERSION_PUBLISHED=true" >> $GITHUB_ENV
222
- else
223
- echo "VERSION_PUBLISHED=false" >> $GITHUB_ENV
224
- fi
225
-
226
- - name: Version Check Results
227
- id: version_check_results
228
- run: |
229
- echo package name: "${{ env.PACKAGE_NAME }}"
230
- echo this: "${{ env.THIS_VERSION }}"
231
- echo latest: "${{ env.LATEST_VERSION }}"
232
- echo this is the latest: "${{ env.LATEST_VERSION == env.THIS_VERSION }}"
233
- echo this version is published: "${{ env.VERSION_PUBLISHED }}"
234
- echo all published versions: $(npm view ${{ env.PACKAGE_NAME }} versions)
235
- echo "::set-output name=version_published::${{ env.VERSION_PUBLISHED }}"
236
-
237
- deploy:
238
- needs: [ check_version ]
239
- name: ๐Ÿš€ Deploy to NPM
240
- runs-on: ubuntu-latest
241
- timeout-minutes: 20
242
- if: ${{ needs.check_version.outputs.version_published != 'true' }}
243
- steps:
244
- - name: Checkout code
245
- uses: actions/checkout@v4
246
-
247
- - name: Set RC
248
- run: |
249
- echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
250
-
251
- - name: Install pnpm
252
- run: |
253
- npm i -g pnpm
254
-
255
- - name: Install Packages
256
- run: |
257
- pnpm i
258
-
259
- - name: Build
260
- run: |
261
- npx tsc
262
-
263
- - name: Pack
264
- run: |
265
- pnpm pack
266
-
267
- - name: Publish
268
- run: |
269
- npm publish
270
-
271
- build_report:
272
- name: ๐Ÿ“Š Build Report
273
- needs: [
274
- notification0,
275
- check_dev_leftovers,
276
- test,
277
- check_version,
278
- deploy
279
- ]
280
- #runs-on: ubuntu-latest
281
- runs-on: plo-koon
282
- timeout-minutes: 20
283
- if: always()
284
- steps:
285
-
286
- # NEW IMPLEMENTATION using futdevpro/fdp-github-actions/send-build-report@master:
287
- - name: Checkout code
288
- uses: actions/checkout@v4
289
-
290
- - name: Send Build Report
291
- uses: futdevpro/fdp-github-actions/send-build-report@master
292
- with:
293
- NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
294
- SETTINGS: |
295
- {
296
- "overseerUrl": "${{ vars.OVERSEER_URL }}",
297
- "overseerSecret": "${{ secrets.OVERSEER_SECRET_KEY }}",
298
- "branchName": "${{ github.ref_name }}",
299
- "repository": "${{ github.repository }}",
300
- "runId": "${{ github.run_id }}",
301
- "linkToAction": "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}",
302
- "eventDateTime": "${{ needs.notification0.outputs.start }}",
303
- "projects": [
304
- {
305
- "environment": "prod",
306
- "stepResults": [
307
- {
308
- "stepName": "checkDevLeftovers",
309
- "resultCode": "${{ needs.check_dev_leftovers.result }}",
310
- "requirement": "optional"
311
- },
312
- {
313
- "stepName": "tests",
314
- "resultCode": "${{ needs.test.result }}",
315
- "requirement": "required"
316
- },
317
- {
318
- "stepName": "checkVersion",
319
- "resultCode": "${{ needs.check_version.result }}",
320
- "requirement": "required"
321
- },
322
- {
323
- "stepName": "deploy",
324
- "resultCode": "${{ needs.deploy.result }}",
325
- "requirement": "optional"
326
- }
327
- ]
328
- }
329
- ]
330
- }
331
-
332
-
333
- end:
334
- name: ๐ŸŽฏ Discord Results
335
- needs: [
336
- notification0,
337
- check_secrets,
338
- check_dev_leftovers,
339
- test,
340
- check_version,
341
- deploy,
342
- build_report
343
- ]
344
- #runs-on: ubuntu-latest
345
- runs-on: plo-koon
346
- timeout-minutes: 20
347
- if: always()
348
- steps:
349
- - name: Checkout code
350
- uses: actions/checkout@v4
351
-
352
- - name: Send Discord result notification
353
- uses: futdevpro/fdp-github-actions/discord-result-notification@latest
24
+ - name: Trigger Overseer Pipeline
25
+ uses: futdevpro/fdp-github-actions/overseer-trigger@master
354
26
  with:
355
- NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
356
- APPLICATION_NAME: "Dynamo-ESLint"
357
- APPLICATION_EMOJI: "๐Ÿ”ง"
358
- BRANCH: ${{ github.ref_name }}
359
- RUN_NUMBER: ${{ github.run_number }}
360
- RUN_ID: ${{ github.run_id }}
361
- REPOSITORY: ${{ github.repository }}
362
- START_TIME: ${{ needs.notification0.outputs.start }}
363
- DISCORD_WEBHOOK_ID: ${{ secrets.DISCORD_WEBHOOK_ID }}
364
- DISCORD_WEBHOOK_TOKEN: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
365
- STEPS_CONFIG: |
366
- [
367
- {
368
- "stepName": "Secrets Check",
369
- "stepEmoji": "๐Ÿ”‘",
370
- "resultCode": "${{ needs.check_secrets.result }}"
371
- },
372
- {
373
- "stepName": "Dev Leftovers Check",
374
- "stepEmoji": "๐Ÿ”",
375
- "resultCode": "${{ needs.check_dev_leftovers.result }}"
376
- },
377
- {
378
- "stepName": "Test Build",
379
- "stepEmoji": "๐Ÿงช",
380
- "resultCode": "${{ needs.test.result }}"
381
- },
382
- {
383
- "stepName": "Check Version",
384
- "stepEmoji": "๐Ÿ”",
385
- "resultCode": "${{ needs.check_version.result }}"
386
- },
387
- {
388
- "stepName": "Deploy",
389
- "stepEmoji": "๐Ÿ“ฆ",
390
- "resultCode": "${{ needs.deploy.result }}",
391
- "specialSuccessEmoji": "๐Ÿš€๐Ÿš€๐Ÿš€"
392
- },
393
- {
394
- "stepName": "Build Report",
395
- "stepEmoji": "๐Ÿ“Š",
396
- "resultCode": "${{ needs.build_report.result }}"
397
- }
398
- ]
399
-
400
-
401
-
27
+ OVERSEER_WEBHOOK_URL: ${{ vars.OVERSEER_URL }}/pipeline-runner/webhook/github
28
+ OVERSEER_WEBHOOK_SECRET: ${{ secrets.OVERSEER_SECRET_KEY }}
29
+
30
+ # =============================================================================
31
+ # REGI WORKFLOW (fallback) โ€” NE TOROLD!
32
+ # =============================================================================
33
+ # name: Test and Deploy
34
+ # on:
35
+ # push:
36
+ # branches:
37
+ # - '**'
38
+ # permissions:
39
+ # actions: read
40
+ # id-token: write
41
+ # contents: read
42
+ # checks: write
43
+ # issues: read
44
+ # pull-requests: write
45
+ # env:
46
+ # PACKAGE_NAME: ''
47
+ # THIS_VERSION: 0.0.0
48
+ # LATEST_VERSION: 0.0.0
49
+ # VERSION_PUBLISHED: true
50
+ #
51
+ #
52
+ # jobs:
53
+ # notification0:
54
+ # name: ๐Ÿน Discord start Notification
55
+ # runs-on: ubuntu-latest
56
+ # #runs-on: plo-koon
57
+ # timeout-minutes: 20
58
+ # outputs:
59
+ # start: ${{ steps.mark_start.outputs.started }}
60
+ # steps:
61
+ # - uses: actions/checkout@v4
62
+ # - id: mark_start
63
+ # run: echo "started=$(date +%s)" >> "$GITHUB_OUTPUT"
64
+ # - name: Send Discord start notification
65
+ # uses: futdevpro/fdp-github-actions/discord-start-notification@latest
66
+ # with:
67
+ # NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
68
+ # APPLICATION_NAME: "Dynamo-ESLint"
69
+ # APPLICATION_EMOJI: "๐Ÿ”ง"
70
+ # COMMIT_MESSAGE: ${{ github.event.head_commit.message }}
71
+ # EVENT_DATETIME: ${{ github.event.head_commit.timestamp }}
72
+ # DISCORD_WEBHOOK_ID: ${{ secrets.DISCORD_WEBHOOK_ID }}
73
+ # DISCORD_WEBHOOK_TOKEN: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
74
+ #
75
+ # notification0_fail_report:
76
+ # name: ๐Ÿ’ฃ Discord Start Notification Fail Report
77
+ # runs-on: ubuntu-latest
78
+ # #runs-on: plo-koon
79
+ # timeout-minutes: 20
80
+ # if: always() && needs.notification0.result == 'failure'
81
+ # needs: [notification0]
82
+ # steps:
83
+ # - name: send custom message with args
84
+ # uses: appleboy/discord-action@master
85
+ # with:
86
+ # webhook_id: ${{ secrets.DISCORD_WEBHOOK_ID }}
87
+ # webhook_token: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
88
+ # message: |
89
+ # โŒโŒโŒ๐Ÿ”ง Failed to send Discord start notification for ${{ github.repository }}! [๐Ÿ”—](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }})
90
+ #
91
+ # check_secrets:
92
+ # name: ๐Ÿ” Check Required Secrets and Variables
93
+ # #runs-on: ubuntu-latest
94
+ # runs-on: plo-koon
95
+ # timeout-minutes: 20
96
+ # steps:
97
+ # - name: Check Required Secrets and Variables
98
+ # uses: futdevpro/fdp-github-actions/check-secrets-and-variables@latest
99
+ # with:
100
+ # NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
101
+ # ITEMS_TO_CHECK: |
102
+ # [
103
+ # {
104
+ # "valueName": "NPM_TOKEN",
105
+ # "value": "${{ secrets.NPM_TOKEN }}",
106
+ # "type": "SECRET"
107
+ # },
108
+ # {
109
+ # "valueName": "DISCORD_WEBHOOK_ID",
110
+ # "value": "${{ secrets.DISCORD_WEBHOOK_ID }}",
111
+ # "type": "SECRET"
112
+ # },
113
+ # {
114
+ # "valueName": "DISCORD_WEBHOOK_TOKEN",
115
+ # "value": "${{ secrets.DISCORD_WEBHOOK_TOKEN }}",
116
+ # "type": "SECRET"
117
+ # },
118
+ # {
119
+ # "valueName": "OVERSEER_SECRET_KEY",
120
+ # "value": "${{ secrets.OVERSEER_SECRET_KEY }}",
121
+ # "type": "SECRET"
122
+ # },
123
+ #
124
+ # {
125
+ # "valueName": "OVERSEER_URL",
126
+ # "value": "${{ vars.OVERSEER_URL }}",
127
+ # "type": "VARIABLE"
128
+ # }
129
+ # ]
130
+ #
131
+ # check_dev_leftovers:
132
+ # name: ๐Ÿ” Check Dev leftovers
133
+ # #runs-on: ubuntu-latest
134
+ # runs-on: plo-koon
135
+ # timeout-minutes: 20
136
+ # steps:
137
+ # - name: Checkout code
138
+ # uses: actions/checkout@v4
139
+ #
140
+ # - name: Install Node.js
141
+ # uses: actions/setup-node@v2
142
+ # with:
143
+ # node-version: '16'
144
+ #
145
+ # # TODO: Check build version (to ALL packages)
146
+ # - name: Check build folder
147
+ # run: |
148
+ # node -e "
149
+ # const buildFolder = './build/';
150
+ # const fs = require('fs');
151
+ #
152
+ # fs.readdir(buildFolder, (err, files) => {
153
+ # if (!files?.length) {
154
+ # console.error(
155
+ # 'FDPError: ./build folder is MISSING!' +
156
+ # '\nbuild the project locally before push!'
157
+ # );
158
+ # process.exit(1);
159
+ # }
160
+ #
161
+ # if (files.includes('dynamo-eslint')) {
162
+ # console.error(
163
+ # 'FDPError: ./build contains dynamo-eslint folder which means this is a local dev build!' +
164
+ # '\nrebuild the project locally before push!'
165
+ # );
166
+ # process.exit(1);
167
+ # }
168
+ # });
169
+ # "
170
+ #
171
+ # test:
172
+ # name: ๐Ÿงช Test Build
173
+ # runs-on: ubuntu-latest
174
+ # needs: [ check_dev_leftovers ]
175
+ # timeout-minutes: 20
176
+ # steps:
177
+ # - name: Checkout code
178
+ # uses: actions/checkout@v4
179
+ #
180
+ # - name: Set NPM RC
181
+ # run: |
182
+ # echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
183
+ #
184
+ # - name: Get safe-chain version
185
+ # run: |
186
+ # VERSION=$(curl -s https://api.github.com/repos/AikidoSec/safe-chain/releases/latest | grep '"tag_name":' | sed -E 's/.*"([^"]+)".*/\1/' | sed 's/^v//')
187
+ # echo "SAFE_CHAIN_VERSION=$VERSION" >> $GITHUB_ENV
188
+ #
189
+ # - name: Install safe-chain
190
+ # run: |
191
+ # curl -fsSL https://raw.githubusercontent.com/AikidoSec/safe-chain/main/install-scripts/install-safe-chain.sh | sh -s -- --ci
192
+ #
193
+ # - name: Install pnpm
194
+ # run: |
195
+ # npm i -g pnpm
196
+ #
197
+ # - name: Install Packages
198
+ # run: |
199
+ # pnpm i --safe-chain-skip-minimum-package-age
200
+ #
201
+ # - name: Build
202
+ # run: |
203
+ # npx tsc
204
+ #
205
+ # - name: Install Jasmine
206
+ # run: |
207
+ # npm i -g jasmine
208
+ #
209
+ # - name: Test
210
+ # run: |
211
+ # jasmine
212
+ #
213
+ # - name: Test Pack
214
+ # run: |
215
+ # pnpm pack
216
+ #
217
+ #
218
+ # check_version:
219
+ # name: ๐Ÿ” Check Version
220
+ # needs: [ test ]
221
+ # #runs-on: ubuntu-latest
222
+ # runs-on: plo-koon
223
+ # timeout-minutes: 20
224
+ # outputs:
225
+ # version_published: ${{ steps.version_check_results.outputs.version_published }}
226
+ # steps:
227
+ # - name: Checkout code
228
+ # uses: actions/checkout@v4
229
+ #
230
+ # - name: Set Package Name
231
+ # run: |
232
+ # echo "PACKAGE_NAME=$(node -p -e "require('./package.json').name")" >> $GITHUB_ENV
233
+ #
234
+ # - name: Set RC
235
+ # run: |
236
+ # echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
237
+ #
238
+ # - name: Get This Version
239
+ # run: |
240
+ # RAW_THIS_VERSION=$(node -p -e "require('./package.json').version")
241
+ # # replace ALL: 'v0' with '', '01' with '1', '.0' with '.'
242
+ # RAW_THIS_VERSION=$(echo $RAW_THIS_VERSION | sed 's:v0::g' | sed 's:01:1:g' | sed -e 's:\.0:\.:g')
243
+ # echo "THIS_VERSION=$RAW_THIS_VERSION" >> $GITHUB_ENV
244
+ #
245
+ # - name: Get Latest Version
246
+ # run: |
247
+ # echo "LATEST_VERSION=$(npm view ${{ env.PACKAGE_NAME }} version)" >> $GITHUB_ENV
248
+ #
249
+ # - name: Check All Versions
250
+ # run: |
251
+ # ALL_VERSIONS=$(npm view ${{ env.PACKAGE_NAME }} versions)
252
+ # if echo "$ALL_VERSIONS" | grep -q "${{ env.THIS_VERSION }}"; then
253
+ # echo "VERSION_PUBLISHED=true" >> $GITHUB_ENV
254
+ # else
255
+ # echo "VERSION_PUBLISHED=false" >> $GITHUB_ENV
256
+ # fi
257
+ #
258
+ # - name: Version Check Results
259
+ # id: version_check_results
260
+ # run: |
261
+ # echo package name: "${{ env.PACKAGE_NAME }}"
262
+ # echo this: "${{ env.THIS_VERSION }}"
263
+ # echo latest: "${{ env.LATEST_VERSION }}"
264
+ # echo this is the latest: "${{ env.LATEST_VERSION == env.THIS_VERSION }}"
265
+ # echo this version is published: "${{ env.VERSION_PUBLISHED }}"
266
+ # echo all published versions: $(npm view ${{ env.PACKAGE_NAME }} versions)
267
+ # echo "::set-output name=version_published::${{ env.VERSION_PUBLISHED }}"
268
+ #
269
+ # deploy:
270
+ # needs: [ check_version ]
271
+ # name: ๐Ÿš€ Deploy to NPM
272
+ # runs-on: ubuntu-latest
273
+ # timeout-minutes: 20
274
+ # if: ${{ needs.check_version.outputs.version_published != 'true' }}
275
+ # steps:
276
+ # - name: Checkout code
277
+ # uses: actions/checkout@v4
278
+ #
279
+ # - name: Set RC
280
+ # run: |
281
+ # echo "//registry.npmjs.org/:_authToken=${{ secrets.NPM_TOKEN }}" > ~/.npmrc
282
+ #
283
+ # - name: Install pnpm
284
+ # run: |
285
+ # npm i -g pnpm
286
+ #
287
+ # - name: Install Packages
288
+ # run: |
289
+ # pnpm i
290
+ #
291
+ # - name: Build
292
+ # run: |
293
+ # npx tsc
294
+ #
295
+ # - name: Pack
296
+ # run: |
297
+ # pnpm pack
298
+ #
299
+ # - name: Publish
300
+ # run: |
301
+ # npm publish
302
+ #
303
+ # build_report:
304
+ # name: ๐Ÿ“Š Build Report
305
+ # needs: [
306
+ # notification0,
307
+ # check_dev_leftovers,
308
+ # test,
309
+ # check_version,
310
+ # deploy
311
+ # ]
312
+ # #runs-on: ubuntu-latest
313
+ # runs-on: plo-koon
314
+ # timeout-minutes: 20
315
+ # if: always()
316
+ # steps:
317
+ #
318
+ # # NEW IMPLEMENTATION using futdevpro/fdp-github-actions/send-build-report@master:
319
+ # - name: Checkout code
320
+ # uses: actions/checkout@v4
321
+ #
322
+ # - name: Send Build Report
323
+ # uses: futdevpro/fdp-github-actions/send-build-report@master
324
+ # with:
325
+ # NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
326
+ # SETTINGS: |
327
+ # {
328
+ # "overseerUrl": "${{ vars.OVERSEER_URL }}",
329
+ # "overseerSecret": "${{ secrets.OVERSEER_SECRET_KEY }}",
330
+ # "branchName": "${{ github.ref_name }}",
331
+ # "repository": "${{ github.repository }}",
332
+ # "runId": "${{ github.run_id }}",
333
+ # "linkToAction": "https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}",
334
+ # "eventDateTime": "${{ needs.notification0.outputs.start }}",
335
+ # "projects": [
336
+ # {
337
+ # "environment": "prod",
338
+ # "stepResults": [
339
+ # {
340
+ # "stepName": "checkDevLeftovers",
341
+ # "resultCode": "${{ needs.check_dev_leftovers.result }}",
342
+ # "requirement": "optional"
343
+ # },
344
+ # {
345
+ # "stepName": "tests",
346
+ # "resultCode": "${{ needs.test.result }}",
347
+ # "requirement": "required"
348
+ # },
349
+ # {
350
+ # "stepName": "checkVersion",
351
+ # "resultCode": "${{ needs.check_version.result }}",
352
+ # "requirement": "required"
353
+ # },
354
+ # {
355
+ # "stepName": "deploy",
356
+ # "resultCode": "${{ needs.deploy.result }}",
357
+ # "requirement": "optional"
358
+ # }
359
+ # ]
360
+ # }
361
+ # ]
362
+ # }
363
+ #
364
+ #
365
+ # end:
366
+ # name: ๐ŸŽฏ Discord Results
367
+ # needs: [
368
+ # notification0,
369
+ # check_secrets,
370
+ # check_dev_leftovers,
371
+ # test,
372
+ # check_version,
373
+ # deploy,
374
+ # build_report
375
+ # ]
376
+ # #runs-on: ubuntu-latest
377
+ # runs-on: plo-koon
378
+ # timeout-minutes: 20
379
+ # if: always()
380
+ # steps:
381
+ # - name: Checkout code
382
+ # uses: actions/checkout@v4
383
+ #
384
+ # - name: Send Discord result notification
385
+ # uses: futdevpro/fdp-github-actions/discord-result-notification@latest
386
+ # with:
387
+ # NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
388
+ # APPLICATION_NAME: "Dynamo-ESLint"
389
+ # APPLICATION_EMOJI: "๐Ÿ”ง"
390
+ # BRANCH: ${{ github.ref_name }}
391
+ # RUN_NUMBER: ${{ github.run_number }}
392
+ # RUN_ID: ${{ github.run_id }}
393
+ # REPOSITORY: ${{ github.repository }}
394
+ # START_TIME: ${{ needs.notification0.outputs.start }}
395
+ # DISCORD_WEBHOOK_ID: ${{ secrets.DISCORD_WEBHOOK_ID }}
396
+ # DISCORD_WEBHOOK_TOKEN: ${{ secrets.DISCORD_WEBHOOK_TOKEN }}
397
+ # STEPS_CONFIG: |
398
+ # [
399
+ # {
400
+ # "stepName": "Secrets Check",
401
+ # "stepEmoji": "๐Ÿ”‘",
402
+ # "resultCode": "${{ needs.check_secrets.result }}"
403
+ # },
404
+ # {
405
+ # "stepName": "Dev Leftovers Check",
406
+ # "stepEmoji": "๐Ÿ”",
407
+ # "resultCode": "${{ needs.check_dev_leftovers.result }}"
408
+ # },
409
+ # {
410
+ # "stepName": "Test Build",
411
+ # "stepEmoji": "๐Ÿงช",
412
+ # "resultCode": "${{ needs.test.result }}"
413
+ # },
414
+ # {
415
+ # "stepName": "Check Version",
416
+ # "stepEmoji": "๐Ÿ”",
417
+ # "resultCode": "${{ needs.check_version.result }}"
418
+ # },
419
+ # {
420
+ # "stepName": "Deploy",
421
+ # "stepEmoji": "๐Ÿ“ฆ",
422
+ # "resultCode": "${{ needs.deploy.result }}",
423
+ # "specialSuccessEmoji": "๐Ÿš€๐Ÿš€๐Ÿš€"
424
+ # },
425
+ # {
426
+ # "stepName": "Build Report",
427
+ # "stepEmoji": "๐Ÿ“Š",
428
+ # "resultCode": "${{ needs.build_report.result }}"
429
+ # }
430
+ # ]