@merkaly/api 0.2.4-5 → 0.2.4-7

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 (260) hide show
  1. package/.DS_Store +0 -0
  2. package/.bin/deploy.sh +9 -0
  3. package/.bin/package.sh +7 -0
  4. package/.docker/Dockerfile +21 -0
  5. package/.dockerignore +12 -0
  6. package/.env +21 -0
  7. package/.eslintignore +8 -0
  8. package/.eslintrc.js +35 -0
  9. package/.github/dependabot.yml +17 -0
  10. package/.github/semantic.yml +5 -0
  11. package/.github/workflows/pull_request.yml +35 -0
  12. package/.gitignore +42 -0
  13. package/.husky/.gitignore +1 -0
  14. package/.husky/commit-msg +5 -0
  15. package/.husky/common.sh +8 -0
  16. package/.husky/pre-commit +5 -0
  17. package/.husky/pre-push +4 -0
  18. package/.idea/.gitignore +5 -0
  19. package/.idea/api.iml +13 -0
  20. package/.idea/codeStyles/codeStyleConfig.xml +5 -0
  21. package/.idea/inspectionProfiles/Project_Default.xml +11 -0
  22. package/.idea/modules.xml +8 -0
  23. package/.idea/vcs.xml +12 -0
  24. package/.idea/workspace.xml +2320 -0
  25. package/.output/modules/sales/orders/billing/billing.entity.d.ts +8 -6
  26. package/.output/modules/sales/orders/billing/billing.entity.js +14 -9
  27. package/.output/modules/sales/orders/billing/billing.types.d.ts +9 -0
  28. package/.output/modules/sales/orders/billing/billing.types.js +14 -0
  29. package/.output/modules/sales/orders/billing/billing.validator.d.ts +6 -10
  30. package/.output/modules/sales/orders/billing/billing.validator.js +10 -15
  31. package/.output/modules/sales/orders/{address → billing/entities}/address.entity.d.ts +2 -1
  32. package/.output/modules/sales/orders/{address → billing/entities}/address.entity.js +17 -17
  33. package/.output/modules/sales/orders/billing/entities/customer.entity.d.ts +5 -0
  34. package/.output/modules/sales/orders/billing/entities/customer.entity.js +52 -0
  35. package/.output/modules/sales/orders/billing/entities/status.entity.d.ts +6 -0
  36. package/.output/modules/sales/orders/billing/entities/status.entity.js +37 -0
  37. package/.output/modules/sales/orders/{address → billing/validators}/address.validator.d.ts +2 -1
  38. package/.output/modules/sales/orders/{address → billing/validators}/address.validator.js +12 -14
  39. package/.output/modules/sales/orders/billing/validators/customer.validator.d.ts +5 -0
  40. package/.output/modules/sales/orders/billing/validators/customer.validator.js +36 -0
  41. package/.output/modules/sales/orders/customer/customer.validator.d.ts +1 -1
  42. package/.output/modules/sales/orders/customer/customer.validator.js +8 -8
  43. package/.output/modules/sales/orders/order.entity.d.ts +1 -1
  44. package/.output/modules/sales/orders/order.validator.d.ts +2 -2
  45. package/.output/modules/sales/orders/order.validator.js +3 -4
  46. package/.output/modules/sales/orders/shipping/entities/address.entity.d.ts +10 -0
  47. package/.output/modules/sales/orders/shipping/entities/address.entity.js +68 -0
  48. package/.output/modules/sales/orders/shipping/entities/customer.entity.d.ts +5 -0
  49. package/.output/modules/sales/orders/shipping/entities/customer.entity.js +52 -0
  50. package/.output/modules/sales/orders/shipping/entities/status.entity.d.ts +6 -0
  51. package/.output/modules/sales/orders/shipping/entities/status.entity.js +37 -0
  52. package/.output/modules/sales/orders/shipping/shipping.entity.d.ts +8 -6
  53. package/.output/modules/sales/orders/shipping/shipping.entity.js +14 -9
  54. package/.output/modules/sales/orders/shipping/shipping.types.d.ts +11 -0
  55. package/.output/modules/sales/orders/shipping/shipping.types.js +16 -0
  56. package/.output/modules/sales/orders/shipping/shipping.validator.d.ts +6 -9
  57. package/.output/modules/sales/orders/shipping/shipping.validator.js +10 -14
  58. package/.output/modules/sales/orders/shipping/validators/address.validator.d.ts +10 -0
  59. package/.output/modules/sales/orders/shipping/validators/address.validator.js +56 -0
  60. package/.output/modules/sales/orders/shipping/validators/customer.validator.d.ts +5 -0
  61. package/.output/modules/sales/orders/shipping/validators/customer.validator.js +36 -0
  62. package/authCertificate.pem +19 -0
  63. package/cloudbuild.yaml +20 -0
  64. package/commitlint.config.js +3 -0
  65. package/jest.config.js +14 -0
  66. package/merkaly-api-0.2.4-6.tgz +0 -0
  67. package/nest-cli.json +9 -0
  68. package/package.json +8 -7
  69. package/serviceAccount.json +7 -0
  70. package/src/abstract/absctract.listener.ts +2 -0
  71. package/src/abstract/abstract.controller.ts +27 -0
  72. package/src/abstract/abstract.entity.ts +19 -0
  73. package/src/abstract/abstract.exception.ts +56 -0
  74. package/src/abstract/abstract.fixture.ts +7 -0
  75. package/src/abstract/abstract.migration.ts +13 -0
  76. package/src/abstract/abstract.repository.ts +79 -0
  77. package/src/abstract/abstract.router.ts +7 -0
  78. package/src/abstract/abstract.validator.ts +62 -0
  79. package/src/app.config.ts +57 -0
  80. package/src/app.console.ts +30 -0
  81. package/src/app.controller.ts +48 -0
  82. package/src/app.migration.ts +7 -0
  83. package/src/app.module.ts +92 -0
  84. package/src/app.strategy.ts +25 -0
  85. package/src/commands/assets.command.ts +38 -0
  86. package/src/commands/deploy.command.ts +6 -0
  87. package/src/commands/fixture.command.ts +11 -0
  88. package/src/commands/generate.command.ts +286 -0
  89. package/src/decorators/public.decorator.ts +5 -0
  90. package/src/decorators/user.decorator.ts +21 -0
  91. package/src/exceptions/missing-identity.exception.ts +11 -0
  92. package/src/exceptions/store-not-implemented.exception.ts +13 -0
  93. package/src/exceptions/store-not-recognized.exception.ts +11 -0
  94. package/src/guards/auth.guard.ts +43 -0
  95. package/src/guards/organization.guard.ts +39 -0
  96. package/src/interceptors/mongo.interceptor.ts +16 -0
  97. package/src/main.ts +37 -0
  98. package/src/middlewares/logger.middleware.ts +15 -0
  99. package/src/middlewares/organization.middleware.ts +76 -0
  100. package/src/migrations/1667226478717-product_price_enhance.ts +29 -0
  101. package/src/migrations/1667329249561-product_add_seo_code_dimension.ts +37 -0
  102. package/src/migrations/1667601099139-product_activve_and_hashtag.ts +35 -0
  103. package/src/migrations/1668136428972-content_banners-use-as-image.ts +56 -0
  104. package/src/migrations/1680483744321-order-billing-shipping-status.ts +32 -0
  105. package/src/modules/assets/asset.controller.ts +33 -0
  106. package/src/modules/assets/asset.entity.ts +26 -0
  107. package/src/modules/assets/asset.module.ts +21 -0
  108. package/src/modules/assets/asset.repository.ts +51 -0
  109. package/src/modules/assets/asset.schema.ts +4 -0
  110. package/src/modules/assets/asset.service.ts +41 -0
  111. package/src/modules/auth/auth.controller.ts +42 -0
  112. package/src/modules/auth/auth.module.ts +18 -0
  113. package/src/modules/auth/logout.ts +0 -0
  114. package/src/modules/command.module.ts +19 -0
  115. package/src/modules/content/banners/banner.controller.ts +56 -0
  116. package/src/modules/content/banners/banner.entity.ts +17 -0
  117. package/src/modules/content/banners/banner.fixture.ts +19 -0
  118. package/src/modules/content/banners/banner.listener.ts +6 -0
  119. package/src/modules/content/banners/banner.module.ts +21 -0
  120. package/src/modules/content/banners/banner.repository.ts +38 -0
  121. package/src/modules/content/banners/banner.schema.ts +4 -0
  122. package/src/modules/content/banners/banner.types.ts +7 -0
  123. package/src/modules/content/banners/banner.validator.ts +19 -0
  124. package/src/modules/content/content.module.ts +20 -0
  125. package/src/modules/content/pages/page.controller.ts +53 -0
  126. package/src/modules/content/pages/page.entity.ts +27 -0
  127. package/src/modules/content/pages/page.fixture.ts +19 -0
  128. package/src/modules/content/pages/page.listener.ts +6 -0
  129. package/src/modules/content/pages/page.module.ts +21 -0
  130. package/src/modules/content/pages/page.repository.ts +44 -0
  131. package/src/modules/content/pages/page.schema.ts +4 -0
  132. package/src/modules/content/pages/page.types.ts +9 -0
  133. package/src/modules/content/pages/page.validator.ts +29 -0
  134. package/src/modules/global.module.ts +70 -0
  135. package/src/modules/insight/controllers/address.controller.ts +29 -0
  136. package/src/modules/insight/controllers/order.controller.ts +70 -0
  137. package/src/modules/insight/controllers/products.controller.ts +18 -0
  138. package/src/modules/insight/insight.module.ts +24 -0
  139. package/src/modules/insight/validators/order.validator.ts +10 -0
  140. package/src/modules/inventory/brands/brand.controller.ts +59 -0
  141. package/src/modules/inventory/brands/brand.entity.ts +14 -0
  142. package/src/modules/inventory/brands/brand.exception.ts +9 -0
  143. package/src/modules/inventory/brands/brand.listener.ts +18 -0
  144. package/src/modules/inventory/brands/brand.module.ts +19 -0
  145. package/src/modules/inventory/brands/brand.repository.ts +39 -0
  146. package/src/modules/inventory/brands/brand.schema.ts +4 -0
  147. package/src/modules/inventory/brands/brand.validator.ts +23 -0
  148. package/src/modules/inventory/categories/category.controller.ts +59 -0
  149. package/src/modules/inventory/categories/category.entity.ts +21 -0
  150. package/src/modules/inventory/categories/category.exception.ts +9 -0
  151. package/src/modules/inventory/categories/category.fixture.ts +18 -0
  152. package/src/modules/inventory/categories/category.listener.ts +17 -0
  153. package/src/modules/inventory/categories/category.module.ts +19 -0
  154. package/src/modules/inventory/categories/category.repository.ts +40 -0
  155. package/src/modules/inventory/categories/category.schema.ts +4 -0
  156. package/src/modules/inventory/categories/category.validator.ts +30 -0
  157. package/src/modules/inventory/inventory.module.ts +22 -0
  158. package/src/modules/inventory/products/entities/code.entity.ts +15 -0
  159. package/src/modules/inventory/products/entities/dimension.entity.ts +18 -0
  160. package/src/modules/inventory/products/entities/price.entity.ts +12 -0
  161. package/src/modules/inventory/products/entities/seo.entity.ts +15 -0
  162. package/src/modules/inventory/products/product.controller.ts +59 -0
  163. package/src/modules/inventory/products/product.entity.ts +53 -0
  164. package/src/modules/inventory/products/product.exception.ts +9 -0
  165. package/src/modules/inventory/products/product.fixture.ts +19 -0
  166. package/src/modules/inventory/products/product.listener.ts +27 -0
  167. package/src/modules/inventory/products/product.module.ts +20 -0
  168. package/src/modules/inventory/products/product.repository.ts +108 -0
  169. package/src/modules/inventory/products/product.schema.ts +15 -0
  170. package/src/modules/inventory/products/product.validator.ts +71 -0
  171. package/src/modules/inventory/products/validators/code.validator.ts +15 -0
  172. package/src/modules/inventory/products/validators/dimension.validator.ts +19 -0
  173. package/src/modules/inventory/products/validators/price.validator.ts +10 -0
  174. package/src/modules/inventory/products/validators/seo.validator.ts +15 -0
  175. package/src/modules/inventory/properties/property.controller.ts +56 -0
  176. package/src/modules/inventory/properties/property.entity.ts +18 -0
  177. package/src/modules/inventory/properties/property.exception.ts +9 -0
  178. package/src/modules/inventory/properties/property.listener.ts +20 -0
  179. package/src/modules/inventory/properties/property.module.ts +21 -0
  180. package/src/modules/inventory/properties/property.repository.ts +23 -0
  181. package/src/modules/inventory/properties/property.schema.ts +4 -0
  182. package/src/modules/inventory/properties/property.validator.ts +27 -0
  183. package/src/modules/sales/clients/client.controller.ts +60 -0
  184. package/src/modules/sales/clients/client.entity.ts +25 -0
  185. package/src/modules/sales/clients/client.exception.ts +9 -0
  186. package/src/modules/sales/clients/client.listener.ts +20 -0
  187. package/src/modules/sales/clients/client.module.ts +19 -0
  188. package/src/modules/sales/clients/client.repository.ts +37 -0
  189. package/src/modules/sales/clients/client.schema.ts +4 -0
  190. package/src/modules/sales/clients/client.validator.ts +43 -0
  191. package/src/modules/sales/orders/billing/billing.entity.ts +22 -0
  192. package/src/modules/sales/orders/billing/billing.types.ts +10 -0
  193. package/src/modules/sales/orders/billing/billing.validator.ts +21 -0
  194. package/src/modules/sales/orders/billing/entities/address.entity.ts +27 -0
  195. package/src/modules/sales/orders/billing/entities/customer.entity.ts +14 -0
  196. package/src/modules/sales/orders/billing/entities/status.entity.ts +16 -0
  197. package/src/modules/sales/orders/billing/validators/address.validator.ts +28 -0
  198. package/src/modules/sales/orders/billing/validators/customer.validator.ts +14 -0
  199. package/src/modules/sales/orders/customer/customer.entity.ts +14 -0
  200. package/src/modules/sales/orders/customer/customer.validator.ts +14 -0
  201. package/src/modules/sales/orders/item/item.entity.ts +21 -0
  202. package/src/modules/sales/orders/item/item.schema.ts +8 -0
  203. package/src/modules/sales/orders/item/item.validator.ts +10 -0
  204. package/src/modules/sales/orders/order.controller.ts +93 -0
  205. package/src/modules/sales/orders/order.entity.ts +47 -0
  206. package/src/modules/sales/orders/order.listener.ts +20 -0
  207. package/src/modules/sales/orders/order.module.ts +19 -0
  208. package/src/modules/sales/orders/order.repository.ts +189 -0
  209. package/src/modules/sales/orders/order.schema.ts +35 -0
  210. package/src/modules/sales/orders/order.validator.ts +72 -0
  211. package/src/modules/sales/orders/shipping/entities/address.entity.ts +27 -0
  212. package/src/modules/sales/orders/shipping/entities/customer.entity.ts +14 -0
  213. package/src/modules/sales/orders/shipping/entities/status.entity.ts +16 -0
  214. package/src/modules/sales/orders/shipping/shipping.entity.ts +25 -0
  215. package/src/modules/sales/orders/shipping/shipping.types.ts +12 -0
  216. package/src/modules/sales/orders/shipping/shipping.validator.ts +25 -0
  217. package/src/modules/sales/orders/shipping/validators/address.validator.ts +28 -0
  218. package/src/modules/sales/orders/shipping/validators/customer.validator.ts +14 -0
  219. package/src/modules/sales/orders/status/status.entity.ts +16 -0
  220. package/src/modules/sales/orders/status/status.validator.ts +8 -0
  221. package/src/modules/sales/sales.module.ts +20 -0
  222. package/src/modules/setting/connections/connection.controller.ts +27 -0
  223. package/src/modules/setting/connections/connection.module.ts +17 -0
  224. package/src/modules/setting/connections/connection.validator.ts +15 -0
  225. package/src/modules/setting/layout/layout.controller.ts +34 -0
  226. package/src/modules/setting/layout/layout.entity.ts +13 -0
  227. package/src/modules/setting/layout/layout.listener.ts +7 -0
  228. package/src/modules/setting/layout/layout.module.ts +21 -0
  229. package/src/modules/setting/layout/layout.repository.ts +29 -0
  230. package/src/modules/setting/layout/layout.schema.ts +4 -0
  231. package/src/modules/setting/members/member.controller.ts +22 -0
  232. package/src/modules/setting/members/member.module.ts +17 -0
  233. package/src/modules/setting/members/member.validator.ts +3 -0
  234. package/src/modules/setting/organization/organization.controller.ts +33 -0
  235. package/src/modules/setting/organization/organization.entity.ts +27 -0
  236. package/src/modules/setting/organization/organization.listener.ts +46 -0
  237. package/src/modules/setting/organization/organization.module.ts +21 -0
  238. package/src/modules/setting/organization/organization.repository.ts +55 -0
  239. package/src/modules/setting/organization/organization.types.ts +65 -0
  240. package/src/modules/setting/organization/organization.validator.ts +56 -0
  241. package/src/modules/setting/setting.module.ts +23 -0
  242. package/src/modules/setting/theme/theme.controller.ts +34 -0
  243. package/src/modules/setting/theme/theme.entity.ts +13 -0
  244. package/src/modules/setting/theme/theme.listener.ts +6 -0
  245. package/src/modules/setting/theme/theme.module.ts +21 -0
  246. package/src/modules/setting/theme/theme.repository.ts +23 -0
  247. package/src/modules/setting/theme/theme.schema.ts +4 -0
  248. package/src/modules/users/user.controller.ts +75 -0
  249. package/src/modules/users/user.module.ts +20 -0
  250. package/src/modules/users/user.validator.ts +28 -0
  251. package/src/providers/auth0.provider.ts +36 -0
  252. package/src/providers/storage.provider.ts +22 -0
  253. package/src/services/auth0.service.ts +7 -0
  254. package/src/services/logger.service.ts +33 -0
  255. package/src/services/mongo.service.ts +44 -0
  256. package/src/services/storage.service.ts +39 -0
  257. package/src/types.ts +19 -0
  258. package/tsconfig.json +40 -0
  259. package/tsconfig.package.json +20 -0
  260. package/yarn.lock +8782 -0
package/.DS_Store ADDED
Binary file
package/.bin/deploy.sh ADDED
@@ -0,0 +1,9 @@
1
+ #!/bin/bash
2
+ rm -frd ./.output
3
+
4
+ yarn clean
5
+
6
+ #yarn console deploy mongo
7
+ #yarn console deploy auth0
8
+
9
+ yarn build
@@ -0,0 +1,7 @@
1
+ #!/bin/bash
2
+ rm -frd ./.output
3
+
4
+ yarn build -p tsconfig.package.json
5
+
6
+ sed 's/extends Document //' .output/abstract/abstract.entity.d.ts > .output/abstract/abstract.entity.ts.d
7
+ mv .output/abstract/abstract.entity.ts.d .output/abstract/abstract.entity.d.ts
@@ -0,0 +1,21 @@
1
+ FROM node:16
2
+
3
+ WORKDIR /usr/src
4
+
5
+ ENV HOST 0.0.0.0
6
+ ENV PORT 6500
7
+
8
+ ARG SENTRY_DSN
9
+ ENV SENTRY_DSN $SENTRY_DSN
10
+
11
+ COPY package.json ./
12
+
13
+ RUN yarn
14
+
15
+ COPY . .
16
+
17
+ RUN yarn build
18
+
19
+ EXPOSE ${PORT}
20
+
21
+ CMD yarn start:prod
package/.dockerignore ADDED
@@ -0,0 +1,12 @@
1
+ /.git
2
+ /.github
3
+ /.husky
4
+ /node_modules
5
+
6
+ # environment vars
7
+ .env
8
+
9
+ # nestjs compiled files
10
+ /**/*.js
11
+ /**/*.map
12
+ /**/*.d.ts
package/.env ADDED
@@ -0,0 +1,21 @@
1
+ PORT=6500
2
+
3
+ AUTH0_DOMAIN=merkaly.us.auth0.com
4
+ AUTH0_CLIENT_ID=eApUjfHoWlMPcTUuU1lqvE517q0KzTh9
5
+ AUTH0_CLIENT_SECRET=be3kiIWcwPONZ1eBO-4V3HVXhrmCqw3vEuA46pCgtAdMMv1p1UrxG77wdCfKX5_j
6
+
7
+ MONGO_HOST=cluster0.1rd8rxv.mongodb.net
8
+ MONGO_USER=kronhyx
9
+ MONGO_PASSWORD=Ujc8WvwRBWvRlfOb
10
+
11
+ ORG_ID=org_h2W8fiEBXpnyvZzY
12
+ USER_ID=google-oauth2|109875342335910059387
13
+
14
+ GCP_BUCKET_NAME=dev.api.merkaly.io
15
+ GOOGLE_ANALYTICS_ID=G-K1HJY7TPPJ
16
+
17
+ ELASTICSEARCH_DSN=production:dXMtY2VudHJhbDEuZ2NwLmNsb3VkLmVzLmlvOjQ0MyQxMTI0N2Y0Mjc3Nzg0ZmU1YTFlYWRhMzY3YWY4OWE0OCQwYTUzMGJkZjUxMDY0NGE5OTVmMDJlNTNlMmIyYmY1Zg==
18
+ ELASTICSEARCH_USERNAME=elastic
19
+ ELASTICSEARCH_PASSWORD=mWzNV5sGvigFUxTT1usaJlan
20
+
21
+ ZIPCODEBASE_APIKEY=52deee90-b0c7-11ed-bcd1-53076faa3d01
package/.eslintignore ADDED
@@ -0,0 +1,8 @@
1
+ jest.config.js
2
+ .eslintrc.js
3
+
4
+ test/**/*.ts
5
+ src/**/*.d.ts
6
+ src/**/*.js
7
+ src/**/*.js.map
8
+ commitlint.config.js
package/.eslintrc.js ADDED
@@ -0,0 +1,35 @@
1
+ module.exports = {
2
+ parser: '@typescript-eslint/parser',
3
+ parserOptions: {
4
+ project: 'tsconfig.json',
5
+ sourceType: 'module'
6
+ },
7
+ plugins: [
8
+ '@typescript-eslint/eslint-plugin'
9
+ ],
10
+ extends: [
11
+ 'plugin:@typescript-eslint/eslint-recommended',
12
+ 'plugin:@typescript-eslint/recommended'
13
+ ],
14
+ root: true,
15
+ env: {
16
+ node: true,
17
+ jest: true
18
+ },
19
+ rules: {
20
+ 'no-multiple-empty-lines': [2, { 'max': 1 }],
21
+ '@typescript-eslint/interface-name-prefix': 'off',
22
+ '@typescript-eslint/explicit-module-boundary-types': 'off',
23
+ '@typescript-eslint/explicit-function-return-type': 'off',
24
+ '@typescript-eslint/no-namespace': 'off',
25
+ '@typescript-eslint/no-explicit-any': 'off'
26
+ },
27
+ 'overrides': [
28
+ {
29
+ 'files': ['./src/**/*.ts'],
30
+ 'rules': {
31
+ '@typescript-eslint/explicit-member-accessibility': ['error']
32
+ }
33
+ }
34
+ ]
35
+ }
@@ -0,0 +1,17 @@
1
+ version: 2
2
+ updates:
3
+ # Fetch and update latest `npm` packages
4
+ - package-ecosystem: npm
5
+ directory: '/'
6
+ schedule:
7
+ interval: daily
8
+ time: '00:00'
9
+ open-pull-requests-limit: 3
10
+ reviewers:
11
+ - kronhyx
12
+ assignees:
13
+ - kronhyx
14
+ commit-message:
15
+ prefix: chore
16
+ prefix-development: chore
17
+ include: scope
@@ -0,0 +1,5 @@
1
+ # Always validate the PR title AND all the commits
2
+ titleAndCommits: true
3
+ # Allows use of Merge commits (eg on github: "Merge branch 'master' into feature/ride-unicorns")
4
+ # this is only relevant when using commitsOnly: true (or titleAndCommits: true)
5
+ allowMergeCommits: true
@@ -0,0 +1,35 @@
1
+ name: PullRequest & Push master
2
+
3
+ env:
4
+ NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
5
+
6
+ on:
7
+ push:
8
+ branches: [ master, release ]
9
+ pull_request:
10
+ branches: [ master, release ]
11
+
12
+ jobs:
13
+ build:
14
+ runs-on: ubuntu-latest
15
+
16
+ steps:
17
+ - name: Checkout 🛎
18
+ uses: actions/checkout@master
19
+
20
+ - name: Setup node env 🏗
21
+ uses: actions/setup-node@v2
22
+ with:
23
+ node-version: 16
24
+
25
+ - name: Install dependencies 🛠️
26
+ run: yarn
27
+
28
+ - name: Lint code 👀️
29
+ run: yarn lint
30
+
31
+ # - name: Run tests 🧪
32
+ # run: yarn test
33
+
34
+ - name: Build code 🛠️
35
+ run: yarn build
package/.gitignore ADDED
@@ -0,0 +1,42 @@
1
+ # compiled output
2
+ /dist
3
+ /node_modules
4
+ /*.tgz
5
+ *.tsbuildinfo
6
+
7
+ # Logs
8
+ *.log
9
+ npm-debug.log*
10
+ yarn-debug.log*
11
+ yarn-error.log*
12
+ lerna-debug.log*
13
+
14
+ # OS
15
+ .DS_Store
16
+
17
+ # Tests
18
+ /coverage
19
+ /.nyc_output
20
+
21
+ # IDEs and editors
22
+ /.idea
23
+ .project
24
+ .classpath
25
+ .c9/
26
+ *.launch
27
+ .settings/
28
+ *.sublime-workspace
29
+
30
+ # IDE - VSCode
31
+ .idea/*
32
+
33
+ # dotenv environment variables file
34
+ .env
35
+ .eslintcache
36
+
37
+ # nestjs compiled files
38
+ /**/*.js
39
+ /**/*.map
40
+ /**/*.d.ts
41
+
42
+ serviceAccount.json
@@ -0,0 +1 @@
1
+ _
@@ -0,0 +1,5 @@
1
+ #!/bin/sh
2
+ . "$(dirname "$0")/_/husky.sh"
3
+ . "$(dirname "$0")/common.sh"
4
+
5
+ yarn commitlint --edit $1
@@ -0,0 +1,8 @@
1
+ command_exists () {
2
+ command -v "$1" >/dev/null 2>&1
3
+ }
4
+
5
+ # Workaround for Windows 10, Git Bash and Yarn
6
+ if command_exists winpty && test -t 1; then
7
+ exec < /dev/tty
8
+ fi
@@ -0,0 +1,5 @@
1
+ #!/bin/sh
2
+ . "$(dirname "$0")/_/husky.sh"
3
+ . "$(dirname "$0")/common.sh"
4
+
5
+ yarn lint-staged
@@ -0,0 +1,4 @@
1
+ #!/bin/sh
2
+ . "$(dirname "$0")/_/husky.sh"
3
+
4
+ yarn build
@@ -0,0 +1,5 @@
1
+ # Default ignored files
2
+ /shelf/
3
+ /workspace.xml
4
+ # Editor-based HTTP Client requests
5
+ /httpRequests/
package/.idea/api.iml ADDED
@@ -0,0 +1,13 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module type="WEB_MODULE" version="4">
3
+ <component name="NewModuleRootManager">
4
+ <content url="file://$MODULE_DIR$">
5
+ <excludeFolder url="file://$MODULE_DIR$/temp" />
6
+ <excludeFolder url="file://$MODULE_DIR$/.tmp" />
7
+ <excludeFolder url="file://$MODULE_DIR$/tmp" />
8
+ <excludeFolder url="file://$MODULE_DIR$/.output" />
9
+ </content>
10
+ <orderEntry type="inheritedJdk" />
11
+ <orderEntry type="sourceFolder" forTests="false" />
12
+ </component>
13
+ </module>
@@ -0,0 +1,5 @@
1
+ <component name="ProjectCodeStyleConfiguration">
2
+ <state>
3
+ <option name="PREFERRED_PROJECT_CODE_STYLE" value="Merkaly" />
4
+ </state>
5
+ </component>
@@ -0,0 +1,11 @@
1
+ <component name="InspectionProjectProfileManager">
2
+ <profile version="1.0">
3
+ <option name="myName" value="Project Default" />
4
+ <inspection_tool class="Eslint" enabled="true" level="WARNING" enabled_by_default="true" />
5
+ <inspection_tool class="SpellCheckingInspection" enabled="false" level="TYPO" enabled_by_default="false">
6
+ <option name="processCode" value="true" />
7
+ <option name="processLiterals" value="true" />
8
+ <option name="processComments" value="true" />
9
+ </inspection_tool>
10
+ </profile>
11
+ </component>
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectModuleManager">
4
+ <modules>
5
+ <module fileurl="file://$PROJECT_DIR$/.idea/api.iml" filepath="$PROJECT_DIR$/.idea/api.iml" />
6
+ </modules>
7
+ </component>
8
+ </project>
package/.idea/vcs.xml ADDED
@@ -0,0 +1,12 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="CommitMessageInspectionProfile">
4
+ <profile version="1.0">
5
+ <inspection_tool class="CommitFormat" enabled="true" level="WARNING" enabled_by_default="true" />
6
+ <inspection_tool class="CommitNamingConvention" enabled="true" level="WARNING" enabled_by_default="true" />
7
+ </profile>
8
+ </component>
9
+ <component name="VcsDirectoryMappings">
10
+ <mapping directory="$PROJECT_DIR$" vcs="Git" />
11
+ </component>
12
+ </project>