clawatch 1.0.21 → 1.0.23

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 (301) hide show
  1. package/backend/dist/db.d.ts +33 -3
  2. package/backend/dist/db.d.ts.map +1 -1
  3. package/backend/dist/db.js +134 -10
  4. package/backend/dist/db.js.map +1 -1
  5. package/backend/dist/index.js +38 -32
  6. package/backend/dist/index.js.map +1 -1
  7. package/backend/dist/routes.d.ts.map +1 -1
  8. package/backend/dist/routes.js +3 -2
  9. package/backend/dist/routes.js.map +1 -1
  10. package/backend/dist/seed.js +115 -109
  11. package/backend/dist/seed.js.map +1 -1
  12. package/backend/node_modules/.package-lock.json +4 -380
  13. package/backend/node_modules/sql.js/.devcontainer/Dockerfile +76 -0
  14. package/backend/node_modules/sql.js/.devcontainer/devcontainer.json +20 -0
  15. package/backend/node_modules/sql.js/.jsdoc.config.json +38 -0
  16. package/backend/node_modules/sql.js/.nojekyll +0 -0
  17. package/backend/node_modules/sql.js/AUTHORS +8 -0
  18. package/backend/node_modules/sql.js/dist/sql-asm-debug.js +140890 -0
  19. package/backend/node_modules/sql.js/dist/sql-asm-memory-growth.js +204 -0
  20. package/backend/node_modules/sql.js/dist/sql-asm.js +202 -0
  21. package/backend/node_modules/sql.js/dist/sql-wasm-browser-debug.js +7157 -0
  22. package/backend/node_modules/sql.js/dist/sql-wasm-browser-debug.wasm +0 -0
  23. package/backend/node_modules/sql.js/dist/sql-wasm-browser.js +183 -0
  24. package/backend/node_modules/sql.js/dist/sql-wasm-browser.wasm +0 -0
  25. package/backend/node_modules/sql.js/dist/sql-wasm-debug.js +7265 -0
  26. package/backend/node_modules/sql.js/dist/sql-wasm-debug.wasm +0 -0
  27. package/backend/node_modules/sql.js/dist/sql-wasm.js +185 -0
  28. package/backend/node_modules/sql.js/dist/sql-wasm.wasm +0 -0
  29. package/backend/node_modules/sql.js/dist/worker.sql-asm-debug.js +141011 -0
  30. package/backend/node_modules/sql.js/dist/worker.sql-asm.js +323 -0
  31. package/backend/node_modules/sql.js/dist/worker.sql-wasm-debug.js +7386 -0
  32. package/backend/node_modules/sql.js/dist/worker.sql-wasm.js +306 -0
  33. package/backend/node_modules/sql.js/eslint.config.cjs +57 -0
  34. package/backend/node_modules/sql.js/logo.svg +13 -0
  35. package/backend/node_modules/sql.js/package.json +58 -0
  36. package/backend/package-lock.json +5 -392
  37. package/backend/package.json +1 -2
  38. package/dist/cli.js +0 -38
  39. package/dist/cli.js.map +1 -1
  40. package/frontend/.next/BUILD_ID +1 -1
  41. package/frontend/.next/build-manifest.json +2 -2
  42. package/frontend/.next/server/app/_global-error.html +2 -2
  43. package/frontend/.next/server/app/_global-error.rsc +1 -1
  44. package/frontend/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  45. package/frontend/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  46. package/frontend/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  47. package/frontend/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  48. package/frontend/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  49. package/frontend/.next/server/app/_not-found.html +1 -1
  50. package/frontend/.next/server/app/_not-found.rsc +1 -1
  51. package/frontend/.next/server/app/_not-found.segments/_full.segment.rsc +1 -1
  52. package/frontend/.next/server/app/_not-found.segments/_head.segment.rsc +1 -1
  53. package/frontend/.next/server/app/_not-found.segments/_index.segment.rsc +1 -1
  54. package/frontend/.next/server/app/_not-found.segments/_not-found/__PAGE__.segment.rsc +1 -1
  55. package/frontend/.next/server/app/_not-found.segments/_not-found.segment.rsc +1 -1
  56. package/frontend/.next/server/app/_not-found.segments/_tree.segment.rsc +1 -1
  57. package/frontend/.next/server/app/dashboard.html +1 -1
  58. package/frontend/.next/server/app/dashboard.rsc +1 -1
  59. package/frontend/.next/server/app/dashboard.segments/_full.segment.rsc +1 -1
  60. package/frontend/.next/server/app/dashboard.segments/_head.segment.rsc +1 -1
  61. package/frontend/.next/server/app/dashboard.segments/_index.segment.rsc +1 -1
  62. package/frontend/.next/server/app/dashboard.segments/_tree.segment.rsc +1 -1
  63. package/frontend/.next/server/app/dashboard.segments/dashboard/__PAGE__.segment.rsc +1 -1
  64. package/frontend/.next/server/app/dashboard.segments/dashboard.segment.rsc +1 -1
  65. package/frontend/.next/server/app/index.html +1 -1
  66. package/frontend/.next/server/app/index.rsc +1 -1
  67. package/frontend/.next/server/app/index.segments/__PAGE__.segment.rsc +1 -1
  68. package/frontend/.next/server/app/index.segments/_full.segment.rsc +1 -1
  69. package/frontend/.next/server/app/index.segments/_head.segment.rsc +1 -1
  70. package/frontend/.next/server/app/index.segments/_index.segment.rsc +1 -1
  71. package/frontend/.next/server/app/index.segments/_tree.segment.rsc +1 -1
  72. package/frontend/.next/server/pages/404.html +1 -1
  73. package/frontend/.next/server/pages/500.html +2 -2
  74. package/package.json +2 -2
  75. package/backend/node_modules/base64-js/base64js.min.js +0 -1
  76. package/backend/node_modules/base64-js/index.d.ts +0 -3
  77. package/backend/node_modules/base64-js/index.js +0 -150
  78. package/backend/node_modules/base64-js/package.json +0 -47
  79. package/backend/node_modules/better-sqlite3/binding.gyp +0 -38
  80. package/backend/node_modules/better-sqlite3/build/Release/better_sqlite3.node +0 -0
  81. package/backend/node_modules/better-sqlite3/deps/common.gypi +0 -68
  82. package/backend/node_modules/better-sqlite3/deps/copy.js +0 -31
  83. package/backend/node_modules/better-sqlite3/deps/defines.gypi +0 -41
  84. package/backend/node_modules/better-sqlite3/deps/download.sh +0 -122
  85. package/backend/node_modules/better-sqlite3/deps/patches/1208.patch +0 -15
  86. package/backend/node_modules/better-sqlite3/deps/sqlite3/sqlite3.c +0 -261480
  87. package/backend/node_modules/better-sqlite3/deps/sqlite3/sqlite3.h +0 -13715
  88. package/backend/node_modules/better-sqlite3/deps/sqlite3/sqlite3ext.h +0 -719
  89. package/backend/node_modules/better-sqlite3/deps/sqlite3.gyp +0 -80
  90. package/backend/node_modules/better-sqlite3/deps/test_extension.c +0 -21
  91. package/backend/node_modules/better-sqlite3/lib/database.js +0 -90
  92. package/backend/node_modules/better-sqlite3/lib/index.js +0 -3
  93. package/backend/node_modules/better-sqlite3/lib/methods/aggregate.js +0 -43
  94. package/backend/node_modules/better-sqlite3/lib/methods/backup.js +0 -67
  95. package/backend/node_modules/better-sqlite3/lib/methods/function.js +0 -31
  96. package/backend/node_modules/better-sqlite3/lib/methods/inspect.js +0 -7
  97. package/backend/node_modules/better-sqlite3/lib/methods/pragma.js +0 -12
  98. package/backend/node_modules/better-sqlite3/lib/methods/serialize.js +0 -16
  99. package/backend/node_modules/better-sqlite3/lib/methods/table.js +0 -189
  100. package/backend/node_modules/better-sqlite3/lib/methods/transaction.js +0 -78
  101. package/backend/node_modules/better-sqlite3/lib/methods/wrappers.js +0 -54
  102. package/backend/node_modules/better-sqlite3/lib/sqlite-error.js +0 -20
  103. package/backend/node_modules/better-sqlite3/lib/util.js +0 -12
  104. package/backend/node_modules/better-sqlite3/package.json +0 -54
  105. package/backend/node_modules/better-sqlite3/src/better_sqlite3.cpp +0 -2186
  106. package/backend/node_modules/better-sqlite3/src/better_sqlite3.hpp +0 -1036
  107. package/backend/node_modules/bindings/bindings.js +0 -221
  108. package/backend/node_modules/bindings/package.json +0 -28
  109. package/backend/node_modules/buffer/index.d.ts +0 -186
  110. package/backend/node_modules/buffer/index.js +0 -1817
  111. package/backend/node_modules/buffer/package.json +0 -96
  112. package/backend/node_modules/chownr/chownr.js +0 -167
  113. package/backend/node_modules/chownr/package.json +0 -29
  114. package/backend/node_modules/decompress-response/index.d.ts +0 -22
  115. package/backend/node_modules/decompress-response/index.js +0 -58
  116. package/backend/node_modules/decompress-response/license +0 -9
  117. package/backend/node_modules/decompress-response/package.json +0 -56
  118. package/backend/node_modules/deep-extend/index.js +0 -1
  119. package/backend/node_modules/deep-extend/lib/deep-extend.js +0 -150
  120. package/backend/node_modules/deep-extend/package.json +0 -62
  121. package/backend/node_modules/detect-libc/index.d.ts +0 -14
  122. package/backend/node_modules/detect-libc/lib/detect-libc.js +0 -313
  123. package/backend/node_modules/detect-libc/lib/elf.js +0 -39
  124. package/backend/node_modules/detect-libc/lib/filesystem.js +0 -51
  125. package/backend/node_modules/detect-libc/lib/process.js +0 -24
  126. package/backend/node_modules/detect-libc/package.json +0 -44
  127. package/backend/node_modules/expand-template/.travis.yml +0 -6
  128. package/backend/node_modules/expand-template/index.js +0 -26
  129. package/backend/node_modules/expand-template/package.json +0 -29
  130. package/backend/node_modules/expand-template/test.js +0 -67
  131. package/backend/node_modules/file-uri-to-path/.travis.yml +0 -30
  132. package/backend/node_modules/file-uri-to-path/index.d.ts +0 -2
  133. package/backend/node_modules/file-uri-to-path/index.js +0 -66
  134. package/backend/node_modules/file-uri-to-path/package.json +0 -32
  135. package/backend/node_modules/fs-constants/browser.js +0 -1
  136. package/backend/node_modules/fs-constants/index.js +0 -1
  137. package/backend/node_modules/fs-constants/package.json +0 -19
  138. package/backend/node_modules/github-from-package/.travis.yml +0 -4
  139. package/backend/node_modules/github-from-package/index.js +0 -17
  140. package/backend/node_modules/github-from-package/package.json +0 -30
  141. package/backend/node_modules/github-from-package/readme.markdown +0 -53
  142. package/backend/node_modules/ieee754/index.d.ts +0 -10
  143. package/backend/node_modules/ieee754/index.js +0 -85
  144. package/backend/node_modules/ieee754/package.json +0 -52
  145. package/backend/node_modules/ini/ini.js +0 -206
  146. package/backend/node_modules/ini/package.json +0 -33
  147. package/backend/node_modules/mimic-response/index.d.ts +0 -17
  148. package/backend/node_modules/mimic-response/index.js +0 -77
  149. package/backend/node_modules/mimic-response/license +0 -9
  150. package/backend/node_modules/mimic-response/package.json +0 -42
  151. package/backend/node_modules/minimist/.github/FUNDING.yml +0 -12
  152. package/backend/node_modules/minimist/.nycrc +0 -14
  153. package/backend/node_modules/minimist/index.js +0 -263
  154. package/backend/node_modules/minimist/package.json +0 -75
  155. package/backend/node_modules/mkdirp-classic/index.js +0 -98
  156. package/backend/node_modules/mkdirp-classic/package.json +0 -18
  157. package/backend/node_modules/napi-build-utils/.github/workflows/run-npm-tests.yml +0 -31
  158. package/backend/node_modules/napi-build-utils/index.js +0 -214
  159. package/backend/node_modules/napi-build-utils/package.json +0 -42
  160. package/backend/node_modules/node-abi/abi_registry.json +0 -432
  161. package/backend/node_modules/node-abi/index.js +0 -179
  162. package/backend/node_modules/node-abi/package.json +0 -45
  163. package/backend/node_modules/prebuild-install/asset.js +0 -44
  164. package/backend/node_modules/prebuild-install/bin.js +0 -78
  165. package/backend/node_modules/prebuild-install/download.js +0 -142
  166. package/backend/node_modules/prebuild-install/error.js +0 -14
  167. package/backend/node_modules/prebuild-install/help.txt +0 -16
  168. package/backend/node_modules/prebuild-install/index.js +0 -1
  169. package/backend/node_modules/prebuild-install/log.js +0 -33
  170. package/backend/node_modules/prebuild-install/node_modules/pump/.github/FUNDING.yml +0 -2
  171. package/backend/node_modules/prebuild-install/node_modules/pump/.travis.yml +0 -5
  172. package/backend/node_modules/prebuild-install/node_modules/pump/LICENSE +0 -21
  173. package/backend/node_modules/prebuild-install/node_modules/pump/README.md +0 -74
  174. package/backend/node_modules/prebuild-install/node_modules/pump/SECURITY.md +0 -5
  175. package/backend/node_modules/prebuild-install/node_modules/pump/empty.js +0 -1
  176. package/backend/node_modules/prebuild-install/node_modules/pump/index.js +0 -86
  177. package/backend/node_modules/prebuild-install/node_modules/pump/package.json +0 -30
  178. package/backend/node_modules/prebuild-install/node_modules/pump/test-browser.js +0 -66
  179. package/backend/node_modules/prebuild-install/node_modules/pump/test-node.js +0 -53
  180. package/backend/node_modules/prebuild-install/package.json +0 -67
  181. package/backend/node_modules/prebuild-install/proxy.js +0 -35
  182. package/backend/node_modules/prebuild-install/rc.js +0 -64
  183. package/backend/node_modules/prebuild-install/util.js +0 -143
  184. package/backend/node_modules/rc/browser.js +0 -7
  185. package/backend/node_modules/rc/cli.js +0 -4
  186. package/backend/node_modules/rc/index.js +0 -53
  187. package/backend/node_modules/rc/lib/utils.js +0 -104
  188. package/backend/node_modules/rc/package.json +0 -29
  189. package/backend/node_modules/semver/bin/semver.js +0 -191
  190. package/backend/node_modules/semver/classes/comparator.js +0 -143
  191. package/backend/node_modules/semver/classes/index.js +0 -7
  192. package/backend/node_modules/semver/classes/range.js +0 -557
  193. package/backend/node_modules/semver/classes/semver.js +0 -333
  194. package/backend/node_modules/semver/functions/clean.js +0 -8
  195. package/backend/node_modules/semver/functions/cmp.js +0 -54
  196. package/backend/node_modules/semver/functions/coerce.js +0 -62
  197. package/backend/node_modules/semver/functions/compare-build.js +0 -9
  198. package/backend/node_modules/semver/functions/compare-loose.js +0 -5
  199. package/backend/node_modules/semver/functions/compare.js +0 -7
  200. package/backend/node_modules/semver/functions/diff.js +0 -60
  201. package/backend/node_modules/semver/functions/eq.js +0 -5
  202. package/backend/node_modules/semver/functions/gt.js +0 -5
  203. package/backend/node_modules/semver/functions/gte.js +0 -5
  204. package/backend/node_modules/semver/functions/inc.js +0 -21
  205. package/backend/node_modules/semver/functions/lt.js +0 -5
  206. package/backend/node_modules/semver/functions/lte.js +0 -5
  207. package/backend/node_modules/semver/functions/major.js +0 -5
  208. package/backend/node_modules/semver/functions/minor.js +0 -5
  209. package/backend/node_modules/semver/functions/neq.js +0 -5
  210. package/backend/node_modules/semver/functions/parse.js +0 -18
  211. package/backend/node_modules/semver/functions/patch.js +0 -5
  212. package/backend/node_modules/semver/functions/prerelease.js +0 -8
  213. package/backend/node_modules/semver/functions/rcompare.js +0 -5
  214. package/backend/node_modules/semver/functions/rsort.js +0 -5
  215. package/backend/node_modules/semver/functions/satisfies.js +0 -12
  216. package/backend/node_modules/semver/functions/sort.js +0 -5
  217. package/backend/node_modules/semver/functions/valid.js +0 -8
  218. package/backend/node_modules/semver/index.js +0 -91
  219. package/backend/node_modules/semver/internal/constants.js +0 -37
  220. package/backend/node_modules/semver/internal/debug.js +0 -11
  221. package/backend/node_modules/semver/internal/identifiers.js +0 -29
  222. package/backend/node_modules/semver/internal/lrucache.js +0 -42
  223. package/backend/node_modules/semver/internal/parse-options.js +0 -17
  224. package/backend/node_modules/semver/internal/re.js +0 -223
  225. package/backend/node_modules/semver/package.json +0 -78
  226. package/backend/node_modules/semver/preload.js +0 -4
  227. package/backend/node_modules/semver/range.bnf +0 -16
  228. package/backend/node_modules/semver/ranges/gtr.js +0 -6
  229. package/backend/node_modules/semver/ranges/intersects.js +0 -9
  230. package/backend/node_modules/semver/ranges/ltr.js +0 -6
  231. package/backend/node_modules/semver/ranges/max-satisfying.js +0 -27
  232. package/backend/node_modules/semver/ranges/min-satisfying.js +0 -26
  233. package/backend/node_modules/semver/ranges/min-version.js +0 -63
  234. package/backend/node_modules/semver/ranges/outside.js +0 -82
  235. package/backend/node_modules/semver/ranges/simplify.js +0 -49
  236. package/backend/node_modules/semver/ranges/subset.js +0 -249
  237. package/backend/node_modules/semver/ranges/to-comparators.js +0 -10
  238. package/backend/node_modules/semver/ranges/valid.js +0 -13
  239. package/backend/node_modules/simple-concat/.travis.yml +0 -3
  240. package/backend/node_modules/simple-concat/index.js +0 -15
  241. package/backend/node_modules/simple-concat/package.json +0 -47
  242. package/backend/node_modules/simple-get/.github/dependabot.yml +0 -15
  243. package/backend/node_modules/simple-get/.github/workflows/ci.yml +0 -23
  244. package/backend/node_modules/simple-get/index.js +0 -108
  245. package/backend/node_modules/simple-get/package.json +0 -67
  246. package/backend/node_modules/strip-json-comments/index.js +0 -70
  247. package/backend/node_modules/strip-json-comments/license +0 -21
  248. package/backend/node_modules/strip-json-comments/package.json +0 -42
  249. package/backend/node_modules/tar-fs/.travis.yml +0 -6
  250. package/backend/node_modules/tar-fs/index.js +0 -363
  251. package/backend/node_modules/tar-fs/node_modules/pump/.github/FUNDING.yml +0 -2
  252. package/backend/node_modules/tar-fs/node_modules/pump/.travis.yml +0 -5
  253. package/backend/node_modules/tar-fs/node_modules/pump/LICENSE +0 -21
  254. package/backend/node_modules/tar-fs/node_modules/pump/README.md +0 -74
  255. package/backend/node_modules/tar-fs/node_modules/pump/SECURITY.md +0 -5
  256. package/backend/node_modules/tar-fs/node_modules/pump/empty.js +0 -1
  257. package/backend/node_modules/tar-fs/node_modules/pump/index.js +0 -86
  258. package/backend/node_modules/tar-fs/node_modules/pump/package.json +0 -30
  259. package/backend/node_modules/tar-fs/node_modules/pump/test-browser.js +0 -66
  260. package/backend/node_modules/tar-fs/node_modules/pump/test-node.js +0 -53
  261. package/backend/node_modules/tar-fs/package.json +0 -41
  262. package/backend/node_modules/tar-stream/extract.js +0 -257
  263. package/backend/node_modules/tar-stream/headers.js +0 -295
  264. package/backend/node_modules/tar-stream/index.js +0 -2
  265. package/backend/node_modules/tar-stream/node_modules/bl/.travis.yml +0 -17
  266. package/backend/node_modules/tar-stream/node_modules/bl/BufferList.js +0 -396
  267. package/backend/node_modules/tar-stream/node_modules/bl/LICENSE.md +0 -13
  268. package/backend/node_modules/tar-stream/node_modules/bl/README.md +0 -247
  269. package/backend/node_modules/tar-stream/node_modules/bl/bl.js +0 -84
  270. package/backend/node_modules/tar-stream/node_modules/bl/package.json +0 -37
  271. package/backend/node_modules/tar-stream/node_modules/readable-stream/CONTRIBUTING.md +0 -38
  272. package/backend/node_modules/tar-stream/node_modules/readable-stream/GOVERNANCE.md +0 -136
  273. package/backend/node_modules/tar-stream/node_modules/readable-stream/LICENSE +0 -47
  274. package/backend/node_modules/tar-stream/node_modules/readable-stream/README.md +0 -106
  275. package/backend/node_modules/tar-stream/node_modules/readable-stream/errors-browser.js +0 -127
  276. package/backend/node_modules/tar-stream/node_modules/readable-stream/errors.js +0 -116
  277. package/backend/node_modules/tar-stream/node_modules/readable-stream/experimentalWarning.js +0 -17
  278. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/_stream_duplex.js +0 -126
  279. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/_stream_passthrough.js +0 -37
  280. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/_stream_readable.js +0 -1027
  281. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/_stream_transform.js +0 -190
  282. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/_stream_writable.js +0 -641
  283. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/async_iterator.js +0 -180
  284. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/buffer_list.js +0 -183
  285. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/destroy.js +0 -96
  286. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/end-of-stream.js +0 -86
  287. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/from-browser.js +0 -3
  288. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/from.js +0 -52
  289. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/pipeline.js +0 -86
  290. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/state.js +0 -22
  291. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/stream-browser.js +0 -1
  292. package/backend/node_modules/tar-stream/node_modules/readable-stream/lib/internal/streams/stream.js +0 -1
  293. package/backend/node_modules/tar-stream/node_modules/readable-stream/package.json +0 -68
  294. package/backend/node_modules/tar-stream/node_modules/readable-stream/readable-browser.js +0 -9
  295. package/backend/node_modules/tar-stream/node_modules/readable-stream/readable.js +0 -16
  296. package/backend/node_modules/tar-stream/pack.js +0 -255
  297. package/backend/node_modules/tar-stream/package.json +0 -58
  298. package/backend/node_modules/tar-stream/sandbox.js +0 -11
  299. /package/frontend/.next/static/{Q4SarPs6hugI0HGjYUgVg → a36G8G-fn_tjHP7E62qvj}/_buildManifest.js +0 -0
  300. /package/frontend/.next/static/{Q4SarPs6hugI0HGjYUgVg → a36G8G-fn_tjHP7E62qvj}/_clientMiddlewareManifest.json +0 -0
  301. /package/frontend/.next/static/{Q4SarPs6hugI0HGjYUgVg → a36G8G-fn_tjHP7E62qvj}/_ssgManifest.js +0 -0
@@ -1,214 +0,0 @@
1
- 'use strict'
2
- // Copyright (c) 2018 inspiredware
3
-
4
- var path = require('path')
5
- var pkg = require(path.resolve('package.json'))
6
-
7
- var versionArray = process.version
8
- .substr(1)
9
- .replace(/-.*$/, '')
10
- .split('.')
11
- .map(function (item) {
12
- return +item
13
- })
14
-
15
- /**
16
- *
17
- * A set of utilities to assist developers of tools that build
18
- * [N-API](https://nodejs.org/api/n-api.html#n_api_n_api) native add-ons.
19
- *
20
- * The main repository can be found
21
- * [here](https://github.com/inspiredware/napi-build-utils#napi-build-utils).
22
- *
23
- * @module napi-build-utils
24
- */
25
-
26
- /**
27
- * Implements a consistent name of `napi` for N-API runtimes.
28
- *
29
- * @param {string} runtime The runtime string.
30
- * @returns {boolean}
31
- */
32
- exports.isNapiRuntime = function (runtime) {
33
- return runtime === 'napi'
34
- }
35
-
36
- /**
37
- * Determines whether the specified N-API version is supported
38
- * by both the currently running Node instance and the package.
39
- *
40
- * @param {string} napiVersion The N-API version to check.
41
- * @returns {boolean}
42
- */
43
- exports.isSupportedVersion = function (napiVersion) {
44
- var version = parseInt(napiVersion, 10)
45
- return version <= exports.getNapiVersion() && exports.packageSupportsVersion(version)
46
- }
47
-
48
- /**
49
- * Determines whether the specified N-API version is supported by the package.
50
- * The N-API version must be present in the `package.json`
51
- * `binary.napi_versions` array.
52
- *
53
- * @param {number} napiVersion The N-API version to check.
54
- * @returns {boolean}
55
- * @private
56
- */
57
- exports.packageSupportsVersion = function (napiVersion) {
58
- if (pkg.binary && pkg.binary.napi_versions &&
59
- pkg.binary.napi_versions instanceof Array) { // integer array
60
- for (var i = 0; i < pkg.binary.napi_versions.length; i++) {
61
- if (pkg.binary.napi_versions[i] === napiVersion) return true
62
- };
63
- };
64
- return false
65
- }
66
-
67
- /**
68
- * Issues a warning to the supplied log if the N-API version is not supported
69
- * by the current Node instance or if the N-API version is not supported
70
- * by the package.
71
- *
72
- * @param {string} napiVersion The N-API version to check.
73
- * @param {Object} log The log object to which the warnings are to be issued.
74
- * Must implement the `warn` method.
75
- */
76
- exports.logUnsupportedVersion = function (napiVersion, log) {
77
- if (!exports.isSupportedVersion(napiVersion)) {
78
- if (exports.packageSupportsVersion(napiVersion)) {
79
- log.warn('This Node instance does not support N-API version ' + napiVersion)
80
- } else {
81
- log.warn('This package does not support N-API version ' + napiVersion)
82
- }
83
- }
84
- }
85
-
86
- /**
87
- * Issues warnings to the supplied log for those N-API versions not supported
88
- * by the N-API runtime or the package.
89
- *
90
- * Note that this function is specific to the
91
- * [`prebuild`](https://github.com/prebuild/prebuild#prebuild) package.
92
- *
93
- * `target` is the list of targets to be built and is determined in one of
94
- * three ways from the command line arguments:
95
- * (1) `--target` specifies a specific target to build.
96
- * (2) `--all` specifies all N-API versions supported by the package.
97
- * (3) Neither of these specifies to build the single "best version available."
98
- *
99
- * `prebuild` is an array of objects in the form `{runtime: 'napi', target: '2'}`.
100
- * The array contains the list of N-API versions that are supported by both the
101
- * package being built and the currently running Node instance.
102
- *
103
- * The objective of this function is to issue a warning for those items that appear
104
- * in the `target` argument but not in the `prebuild` argument.
105
- * If a specific target is supported by the package (`packageSupportsVersion`) but
106
- * but note in `prebuild`, the assumption is that the target is not supported by
107
- * Node.
108
- *
109
- * @param {(Array<string>|string)} target The N-API version(s) to check. Target is
110
- * @param {Array<Object>} prebuild A config object created by the `prebuild` package.
111
- * @param {Object} log The log object to which the warnings are to be issued.
112
- * Must implement the `warn` method.
113
- * @private
114
- */
115
- exports.logMissingNapiVersions = function (target, prebuild, log) {
116
- if (exports.getNapiBuildVersions()) {
117
- var targets = [].concat(target)
118
- targets.forEach(function (napiVersion) {
119
- if (!prebuildExists(prebuild, napiVersion)) {
120
- if (exports.packageSupportsVersion(parseInt(napiVersion, 10))) {
121
- log.warn('This Node instance does not support N-API version ' + napiVersion)
122
- } else {
123
- log.warn('This package does not support N-API version ' + napiVersion)
124
- }
125
- }
126
- })
127
- } else {
128
- log.error('Builds with runtime \'napi\' require a binary.napi_versions ' +
129
- 'property on the package.json file')
130
- }
131
- }
132
-
133
- /**
134
- * Determines whether the specified N-API version exists in the prebuild
135
- * configuration object.
136
- *
137
- * Note that this function is specific to the `prebuild` and `prebuild-install`
138
- * packages.
139
- *
140
- * @param {Object} prebuild A config object created by the `prebuild` package.
141
- * @param {string} napiVersion The N-APi version to be checked.
142
- * @return {boolean}
143
- * @private
144
- */
145
- var prebuildExists = function (prebuild, napiVersion) {
146
- if (prebuild) {
147
- for (var i = 0; i < prebuild.length; i++) {
148
- if (prebuild[i].target === napiVersion) return true
149
- }
150
- }
151
- return false
152
- }
153
-
154
- /**
155
- * Returns the best N-API version to build given the highest N-API
156
- * version supported by the current Node instance and the N-API versions
157
- * supported by the package, or undefined if a suitable N-API version
158
- * cannot be determined.
159
- *
160
- * The best build version is the greatest N-API version supported by
161
- * the package that is less than or equal to the highest N-API version
162
- * supported by the current Node instance.
163
- *
164
- * @returns {number|undefined}
165
- */
166
- exports.getBestNapiBuildVersion = function () {
167
- var bestNapiBuildVersion = 0
168
- var napiBuildVersions = exports.getNapiBuildVersions(pkg) // array of integer strings
169
- if (napiBuildVersions) {
170
- var ourNapiVersion = exports.getNapiVersion()
171
- napiBuildVersions.forEach(function (napiBuildVersionStr) {
172
- var napiBuildVersion = parseInt(napiBuildVersionStr, 10)
173
- if (napiBuildVersion > bestNapiBuildVersion &&
174
- napiBuildVersion <= ourNapiVersion) {
175
- bestNapiBuildVersion = napiBuildVersion
176
- }
177
- })
178
- }
179
- return bestNapiBuildVersion === 0 ? undefined : bestNapiBuildVersion
180
- }
181
-
182
- /**
183
- * Returns an array of N-API versions supported by the package.
184
- *
185
- * @returns {Array<string>|undefined}
186
- */
187
- exports.getNapiBuildVersions = function () {
188
- var napiBuildVersions = []
189
- // remove duplicates, convert to text
190
- if (pkg.binary && pkg.binary.napi_versions) {
191
- pkg.binary.napi_versions.forEach(function (napiVersion) {
192
- var duplicated = napiBuildVersions.indexOf('' + napiVersion) !== -1
193
- if (!duplicated) {
194
- napiBuildVersions.push('' + napiVersion)
195
- }
196
- })
197
- }
198
- return napiBuildVersions.length ? napiBuildVersions : undefined
199
- }
200
-
201
- /**
202
- * Returns the highest N-API version supported by the current node instance
203
- * or undefined if N-API is not supported.
204
- *
205
- * @returns {string|undefined}
206
- */
207
- exports.getNapiVersion = function () {
208
- var version = process.versions.napi // integer string, can be undefined
209
- if (!version) { // this code should never need to be updated
210
- if (versionArray[0] === 9 && versionArray[1] >= 3) version = '2' // 9.3.0+
211
- else if (versionArray[0] === 8) version = '1' // 8.0.0+
212
- }
213
- return version
214
- }
@@ -1,42 +0,0 @@
1
- {
2
- "name": "napi-build-utils",
3
- "version": "2.0.0",
4
- "description": "A set of utilities to assist developers of tools that build N-API native add-ons",
5
- "main": "index.js",
6
- "scripts": {
7
- "doc": "jsdoc2md index.js >index.md",
8
- "test": "mocha test/ && npm run lint",
9
- "lint": "standard",
10
- "prepublishOnly": "npm run test"
11
- },
12
- "keywords": [
13
- "n-api",
14
- "prebuild",
15
- "prebuild-install"
16
- ],
17
- "author": "Jim Schlight",
18
- "license": "MIT",
19
- "homepage": "https://github.com/inspiredware/napi-build-utils#readme",
20
- "repository": {
21
- "type": "git",
22
- "url": "git+https://github.com/inspiredware/napi-build-utils.git"
23
- },
24
- "bugs": {
25
- "url": "https://github.com/inspiredware/napi-build-utils/issues"
26
- },
27
- "devDependencies": {
28
- "chai": "^4.1.2",
29
- "jsdoc-to-markdown": "^4.0.1",
30
- "mocha": "^5.2.0",
31
- "standard": "^12.0.1"
32
- },
33
- "binary": {
34
- "note": "napi-build-tools is not an N-API module. This entry is for unit testing.",
35
- "napi_versions": [
36
- 2,
37
- 2,
38
- 3,
39
- 10
40
- ]
41
- }
42
- }
@@ -1,432 +0,0 @@
1
- [
2
- {
3
- "runtime": "node",
4
- "target": "11.0.0",
5
- "lts": false,
6
- "future": false,
7
- "abi": "67"
8
- },
9
- {
10
- "runtime": "node",
11
- "target": "12.0.0",
12
- "lts": [
13
- "2019-10-21",
14
- "2020-11-30"
15
- ],
16
- "future": false,
17
- "abi": "72"
18
- },
19
- {
20
- "runtime": "node",
21
- "target": "13.0.0",
22
- "lts": false,
23
- "future": false,
24
- "abi": "79"
25
- },
26
- {
27
- "runtime": "node",
28
- "target": "14.0.0",
29
- "lts": [
30
- "2020-10-27",
31
- "2021-10-19"
32
- ],
33
- "future": false,
34
- "abi": "83"
35
- },
36
- {
37
- "runtime": "node",
38
- "target": "15.0.0",
39
- "lts": false,
40
- "future": false,
41
- "abi": "88"
42
- },
43
- {
44
- "runtime": "node",
45
- "target": "16.0.0",
46
- "lts": [
47
- "2021-10-26",
48
- "2022-10-18"
49
- ],
50
- "future": false,
51
- "abi": "93"
52
- },
53
- {
54
- "runtime": "node",
55
- "target": "17.0.0",
56
- "lts": false,
57
- "future": false,
58
- "abi": "102"
59
- },
60
- {
61
- "runtime": "node",
62
- "target": "18.0.0",
63
- "lts": [
64
- "2022-10-25",
65
- "2023-10-18"
66
- ],
67
- "future": false,
68
- "abi": "108"
69
- },
70
- {
71
- "runtime": "node",
72
- "target": "19.0.0",
73
- "lts": false,
74
- "future": false,
75
- "abi": "111"
76
- },
77
- {
78
- "runtime": "node",
79
- "target": "20.0.0",
80
- "lts": [
81
- "2023-10-24",
82
- "2024-10-22"
83
- ],
84
- "future": false,
85
- "abi": "115"
86
- },
87
- {
88
- "runtime": "node",
89
- "target": "21.0.0",
90
- "lts": false,
91
- "future": false,
92
- "abi": "120"
93
- },
94
- {
95
- "runtime": "node",
96
- "target": "22.0.0",
97
- "lts": [
98
- "2024-10-29",
99
- "2025-10-21"
100
- ],
101
- "future": false,
102
- "abi": "127"
103
- },
104
- {
105
- "runtime": "node",
106
- "target": "23.0.0",
107
- "lts": false,
108
- "future": false,
109
- "abi": "131"
110
- },
111
- {
112
- "runtime": "node",
113
- "target": "24.0.0",
114
- "lts": [
115
- "2025-10-28",
116
- "2026-10-20"
117
- ],
118
- "future": false,
119
- "abi": "137"
120
- },
121
- {
122
- "runtime": "node",
123
- "target": "25.0.0",
124
- "lts": false,
125
- "future": false,
126
- "abi": "141"
127
- },
128
- {
129
- "runtime": "node",
130
- "target": "26.0.0",
131
- "lts": [
132
- "2026-10-28",
133
- "2027-10-20"
134
- ],
135
- "future": true,
136
- "abi": "144"
137
- },
138
- {
139
- "abi": "70",
140
- "future": false,
141
- "lts": false,
142
- "runtime": "electron",
143
- "target": "5.0.0-beta.9"
144
- },
145
- {
146
- "abi": "73",
147
- "future": false,
148
- "lts": false,
149
- "runtime": "electron",
150
- "target": "6.0.0-beta.1"
151
- },
152
- {
153
- "abi": "75",
154
- "future": false,
155
- "lts": false,
156
- "runtime": "electron",
157
- "target": "7.0.0-beta.1"
158
- },
159
- {
160
- "abi": "76",
161
- "future": false,
162
- "lts": false,
163
- "runtime": "electron",
164
- "target": "9.0.0-beta.1"
165
- },
166
- {
167
- "abi": "76",
168
- "future": false,
169
- "lts": false,
170
- "runtime": "electron",
171
- "target": "8.0.0-beta.1"
172
- },
173
- {
174
- "abi": "80",
175
- "future": false,
176
- "lts": false,
177
- "runtime": "electron",
178
- "target": "9.0.0-beta.2"
179
- },
180
- {
181
- "abi": "82",
182
- "future": false,
183
- "lts": false,
184
- "runtime": "electron",
185
- "target": "11.0.0-beta.1"
186
- },
187
- {
188
- "abi": "82",
189
- "future": false,
190
- "lts": false,
191
- "runtime": "electron",
192
- "target": "10.0.0-beta.1"
193
- },
194
- {
195
- "abi": "85",
196
- "future": false,
197
- "lts": false,
198
- "runtime": "electron",
199
- "target": "11.0.0-beta.11"
200
- },
201
- {
202
- "abi": "87",
203
- "future": false,
204
- "lts": false,
205
- "runtime": "electron",
206
- "target": "12.0.0-beta.1"
207
- },
208
- {
209
- "abi": "89",
210
- "future": false,
211
- "lts": false,
212
- "runtime": "electron",
213
- "target": "15.0.0-alpha.1"
214
- },
215
- {
216
- "abi": "89",
217
- "future": false,
218
- "lts": false,
219
- "runtime": "electron",
220
- "target": "14.0.0-beta.1"
221
- },
222
- {
223
- "abi": "89",
224
- "future": false,
225
- "lts": false,
226
- "runtime": "electron",
227
- "target": "13.0.0-beta.2"
228
- },
229
- {
230
- "abi": "97",
231
- "future": false,
232
- "lts": false,
233
- "runtime": "electron",
234
- "target": "14.0.2"
235
- },
236
- {
237
- "abi": "98",
238
- "future": false,
239
- "lts": false,
240
- "runtime": "electron",
241
- "target": "15.0.0-beta.7"
242
- },
243
- {
244
- "abi": "99",
245
- "future": false,
246
- "lts": false,
247
- "runtime": "electron",
248
- "target": "16.0.0-alpha.1"
249
- },
250
- {
251
- "abi": "101",
252
- "future": false,
253
- "lts": false,
254
- "runtime": "electron",
255
- "target": "17.0.0-alpha.1"
256
- },
257
- {
258
- "abi": "103",
259
- "future": false,
260
- "lts": false,
261
- "runtime": "electron",
262
- "target": "18.0.0-alpha.1"
263
- },
264
- {
265
- "abi": "106",
266
- "future": false,
267
- "lts": false,
268
- "runtime": "electron",
269
- "target": "19.0.0-alpha.1"
270
- },
271
- {
272
- "abi": "107",
273
- "future": false,
274
- "lts": false,
275
- "runtime": "electron",
276
- "target": "20.0.0-alpha.1"
277
- },
278
- {
279
- "abi": "109",
280
- "future": false,
281
- "lts": false,
282
- "runtime": "electron",
283
- "target": "21.0.0-alpha.1"
284
- },
285
- {
286
- "abi": "110",
287
- "future": false,
288
- "lts": false,
289
- "runtime": "electron",
290
- "target": "22.0.0-alpha.1"
291
- },
292
- {
293
- "abi": "113",
294
- "future": false,
295
- "lts": false,
296
- "runtime": "electron",
297
- "target": "23.0.0-alpha.1"
298
- },
299
- {
300
- "abi": "114",
301
- "future": false,
302
- "lts": false,
303
- "runtime": "electron",
304
- "target": "24.0.0-alpha.1"
305
- },
306
- {
307
- "abi": "116",
308
- "future": false,
309
- "lts": false,
310
- "runtime": "electron",
311
- "target": "26.0.0-alpha.1"
312
- },
313
- {
314
- "abi": "116",
315
- "future": false,
316
- "lts": false,
317
- "runtime": "electron",
318
- "target": "25.0.0-alpha.1"
319
- },
320
- {
321
- "abi": "118",
322
- "future": false,
323
- "lts": false,
324
- "runtime": "electron",
325
- "target": "27.0.0-alpha.1"
326
- },
327
- {
328
- "abi": "119",
329
- "future": false,
330
- "lts": false,
331
- "runtime": "electron",
332
- "target": "28.0.0-alpha.1"
333
- },
334
- {
335
- "abi": "121",
336
- "future": false,
337
- "lts": false,
338
- "runtime": "electron",
339
- "target": "29.0.0-alpha.1"
340
- },
341
- {
342
- "abi": "123",
343
- "future": false,
344
- "lts": false,
345
- "runtime": "electron",
346
- "target": "31.0.0-alpha.1"
347
- },
348
- {
349
- "abi": "123",
350
- "future": false,
351
- "lts": false,
352
- "runtime": "electron",
353
- "target": "30.0.0-alpha.1"
354
- },
355
- {
356
- "abi": "125",
357
- "future": false,
358
- "lts": false,
359
- "runtime": "electron",
360
- "target": "31.0.0-beta.7"
361
- },
362
- {
363
- "abi": "128",
364
- "future": false,
365
- "lts": false,
366
- "runtime": "electron",
367
- "target": "32.0.0-alpha.1"
368
- },
369
- {
370
- "abi": "130",
371
- "future": false,
372
- "lts": false,
373
- "runtime": "electron",
374
- "target": "33.0.0-alpha.1"
375
- },
376
- {
377
- "abi": "132",
378
- "future": false,
379
- "lts": false,
380
- "runtime": "electron",
381
- "target": "34.0.0-alpha.1"
382
- },
383
- {
384
- "abi": "133",
385
- "future": false,
386
- "lts": false,
387
- "runtime": "electron",
388
- "target": "35.0.0-alpha.1"
389
- },
390
- {
391
- "abi": "135",
392
- "future": false,
393
- "lts": false,
394
- "runtime": "electron",
395
- "target": "36.0.0-alpha.1"
396
- },
397
- {
398
- "abi": "136",
399
- "future": false,
400
- "lts": false,
401
- "runtime": "electron",
402
- "target": "37.0.0-alpha.1"
403
- },
404
- {
405
- "abi": "139",
406
- "future": false,
407
- "lts": false,
408
- "runtime": "electron",
409
- "target": "38.0.0-alpha.1"
410
- },
411
- {
412
- "abi": "140",
413
- "future": false,
414
- "lts": false,
415
- "runtime": "electron",
416
- "target": "39.0.0-alpha.1"
417
- },
418
- {
419
- "abi": "143",
420
- "future": false,
421
- "lts": false,
422
- "runtime": "electron",
423
- "target": "40.0.0-alpha.2"
424
- },
425
- {
426
- "abi": "145",
427
- "future": true,
428
- "lts": false,
429
- "runtime": "electron",
430
- "target": "41.0.0-alpha.1"
431
- }
432
- ]