@erinjs/core 1.0.0 → 1.2.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/{core/LICENSE → LICENSE} +203 -203
- package/README.md +46 -0
- package/dist/index.d.mts +2084 -0
- package/dist/index.d.ts +2084 -0
- package/dist/index.js +3867 -0
- package/dist/index.mjs +3809 -0
- package/package.json +50 -15
- package/core/.changeset/README.md +0 -8
- package/core/.changeset/community-bootstrap-release.md +0 -17
- package/core/.changeset/config.json +0 -11
- package/core/.changeset/no-changelog.js +0 -16
- package/core/.changeset/pre.json +0 -17
- package/core/.editorconfig +0 -13
- package/core/.gitattributes +0 -2
- package/core/.github/CODE_OF_CONDUCT.md +0 -23
- package/core/.github/FUNDING.yml +0 -7
- package/core/.github/ISSUE_TEMPLATE/bug_report.md +0 -31
- package/core/.github/ISSUE_TEMPLATE/feature_request.md +0 -23
- package/core/.github/PULL_REQUEST_TEMPLATE.md +0 -16
- package/core/.github/dependabot.yml +0 -16
- package/core/.github/workflows/autoapp.yml +0 -16
- package/core/.github/workflows/ci.yml +0 -187
- package/core/.github/workflows/codeql.yml +0 -30
- package/core/.github/workflows/deploy-docs.yml +0 -54
- package/core/.github/workflows/publish.yml +0 -43
- package/core/.lintstagedrc.json +0 -4
- package/core/.nvmrc +0 -1
- package/core/.prettierignore +0 -8
- package/core/.prettierrc +0 -11
- package/core/CONTRIBUTING.md +0 -70
- package/core/README.md +0 -61
- package/core/SECURITY.md +0 -21
- package/core/apps/docs/index.html +0 -28
- package/core/apps/docs/middleware.ts +0 -21
- package/core/apps/docs/package.json +0 -33
- package/core/apps/docs/public/@flux.png +0 -0
- package/core/apps/docs/public/docs/latest/guides.json +0 -1420
- package/core/apps/docs/public/docs/latest/main.json +0 -14981
- package/core/apps/docs/public/docs/latest/rag-index.json +0 -1
- package/core/apps/docs/public/docs/v1.0.5/guides.json +0 -226
- package/core/apps/docs/public/docs/v1.0.5/main.json +0 -7920
- package/core/apps/docs/public/docs/v1.0.6/guides.json +0 -226
- package/core/apps/docs/public/docs/v1.0.6/main.json +0 -7920
- package/core/apps/docs/public/docs/v1.0.7/guides.json +0 -259
- package/core/apps/docs/public/docs/v1.0.7/main.json +0 -8652
- package/core/apps/docs/public/docs/v1.0.8/guides.json +0 -313
- package/core/apps/docs/public/docs/v1.0.8/main.json +0 -9618
- package/core/apps/docs/public/docs/v1.0.9/guides.json +0 -319
- package/core/apps/docs/public/docs/v1.0.9/main.json +0 -10694
- package/core/apps/docs/public/docs/v1.1.0/guides.json +0 -589
- package/core/apps/docs/public/docs/v1.1.0/main.json +0 -12576
- package/core/apps/docs/public/docs/v1.1.2/guides.json +0 -650
- package/core/apps/docs/public/docs/v1.1.2/main.json +0 -13239
- package/core/apps/docs/public/docs/v1.1.3/guides.json +0 -650
- package/core/apps/docs/public/docs/v1.1.3/main.json +0 -13239
- package/core/apps/docs/public/docs/v1.1.4/guides.json +0 -708
- package/core/apps/docs/public/docs/v1.1.4/main.json +0 -13231
- package/core/apps/docs/public/docs/v1.1.5/guides.json +0 -1035
- package/core/apps/docs/public/docs/v1.1.5/main.json +0 -13838
- package/core/apps/docs/public/docs/v1.1.6/guides.json +0 -1041
- package/core/apps/docs/public/docs/v1.1.6/main.json +0 -14313
- package/core/apps/docs/public/docs/v1.1.8/guides.json +0 -1047
- package/core/apps/docs/public/docs/v1.1.8/main.json +0 -14421
- package/core/apps/docs/public/docs/v1.1.9/guides.json +0 -1047
- package/core/apps/docs/public/docs/v1.1.9/main.json +0 -14421
- package/core/apps/docs/public/docs/v1.2.0/guides.json +0 -1212
- package/core/apps/docs/public/docs/v1.2.0/main.json +0 -14663
- package/core/apps/docs/public/docs/v1.2.1/guides.json +0 -1293
- package/core/apps/docs/public/docs/v1.2.1/main.json +0 -14828
- package/core/apps/docs/public/docs/v1.2.2/guides.json +0 -1293
- package/core/apps/docs/public/docs/v1.2.2/main.json +0 -15025
- package/core/apps/docs/public/docs/v1.2.3/guides.json +0 -1420
- package/core/apps/docs/public/docs/v1.2.3/main.json +0 -14954
- package/core/apps/docs/public/docs/v1.2.4/guides.json +0 -1420
- package/core/apps/docs/public/docs/v1.2.4/main.json +0 -14981
- package/core/apps/docs/public/docs/versions.json +0 -24
- package/core/apps/docs/public/flux.png +0 -0
- package/core/apps/docs/public/locales/en.json +0 -50
- package/core/apps/docs/public/locales/guides-en.json +0 -512
- package/core/apps/docs/public/robots.txt +0 -4
- package/core/apps/docs/public/sitemap.xml +0 -33
- package/core/apps/docs/src/App.vue +0 -538
- package/core/apps/docs/src/components/ApiCategorySection.vue +0 -42
- package/core/apps/docs/src/components/ApiDiscordCompat.vue +0 -65
- package/core/apps/docs/src/components/ApiEndpointCard.vue +0 -313
- package/core/apps/docs/src/components/ApiSchemaBlock.vue +0 -131
- package/core/apps/docs/src/components/CodeBlock.vue +0 -177
- package/core/apps/docs/src/components/CommunityCallout.vue +0 -90
- package/core/apps/docs/src/components/ConstructorSection.vue +0 -82
- package/core/apps/docs/src/components/DocDescription.vue +0 -40
- package/core/apps/docs/src/components/FluxerLogo.vue +0 -3
- package/core/apps/docs/src/components/Footer.vue +0 -106
- package/core/apps/docs/src/components/GuideCodeBlock.vue +0 -102
- package/core/apps/docs/src/components/GuideDiscordCompat.vue +0 -77
- package/core/apps/docs/src/components/GuideDiscordCompatCallout.vue +0 -83
- package/core/apps/docs/src/components/GuideTable.vue +0 -77
- package/core/apps/docs/src/components/GuideTip.vue +0 -38
- package/core/apps/docs/src/components/MethodsSection.vue +0 -195
- package/core/apps/docs/src/components/ParamsTable.vue +0 -70
- package/core/apps/docs/src/components/PropertiesSection.vue +0 -143
- package/core/apps/docs/src/components/SearchBar.vue +0 -76
- package/core/apps/docs/src/components/SearchModal.vue +0 -361
- package/core/apps/docs/src/components/SidebarNav.vue +0 -225
- package/core/apps/docs/src/components/SponsorBanner.vue +0 -153
- package/core/apps/docs/src/components/TypeSignature.vue +0 -187
- package/core/apps/docs/src/components/VersionPicker.vue +0 -191
- package/core/apps/docs/src/composables/useSearchIndex.ts +0 -144
- package/core/apps/docs/src/composables/useVersionedPath.ts +0 -20
- package/core/apps/docs/src/data/apiEndpoints.ts +0 -1073
- package/core/apps/docs/src/data/changelog.ts +0 -717
- package/core/apps/docs/src/data/guides.ts +0 -2362
- package/core/apps/docs/src/env.d.ts +0 -7
- package/core/apps/docs/src/locales/guides-en.json +0 -512
- package/core/apps/docs/src/main.ts +0 -27
- package/core/apps/docs/src/pages/ApiReferenceLayout.vue +0 -175
- package/core/apps/docs/src/pages/ApiReferencePage.vue +0 -128
- package/core/apps/docs/src/pages/Changelog.vue +0 -288
- package/core/apps/docs/src/pages/ClassPage.vue +0 -319
- package/core/apps/docs/src/pages/ClassesList.vue +0 -100
- package/core/apps/docs/src/pages/DocsLayout.vue +0 -127
- package/core/apps/docs/src/pages/GuidePage.vue +0 -279
- package/core/apps/docs/src/pages/GuidesIndex.vue +0 -166
- package/core/apps/docs/src/pages/GuidesLayout.vue +0 -245
- package/core/apps/docs/src/pages/Home.vue +0 -125
- package/core/apps/docs/src/pages/NotFound.vue +0 -57
- package/core/apps/docs/src/pages/TypedefPage.vue +0 -230
- package/core/apps/docs/src/pages/TypedefsList.vue +0 -168
- package/core/apps/docs/src/pages/VersionLayout.vue +0 -15
- package/core/apps/docs/src/router.ts +0 -73
- package/core/apps/docs/src/stores/docs.ts +0 -54
- package/core/apps/docs/src/stores/guides.ts +0 -53
- package/core/apps/docs/src/stores/version.ts +0 -67
- package/core/apps/docs/src/styles/main.css +0 -278
- package/core/apps/docs/src/styles/prism.css +0 -95
- package/core/apps/docs/src/types/doc-schema.ts +0 -112
- package/core/apps/docs/tsconfig.json +0 -17
- package/core/apps/docs/tsconfig.node.json +0 -10
- package/core/apps/docs/vite.config.d.ts +0 -2
- package/core/apps/docs/vite.config.js +0 -26
- package/core/apps/docs/vite.config.ts +0 -28
- package/core/apps/docs-vitepress/.vitepress/config.ts +0 -141
- package/core/apps/docs-vitepress/api-data/latest/main.json +0 -15035
- package/core/apps/docs-vitepress/api-data/v1.2.4/main.json +0 -15035
- package/core/apps/docs-vitepress/api-data/versions.json +0 -6
- package/core/apps/docs-vitepress/index.md +0 -15
- package/core/apps/docs-vitepress/package-lock.json +0 -2924
- package/core/apps/docs-vitepress/package.json +0 -20
- package/core/apps/docs-vitepress/public/CNAME +0 -1
- package/core/apps/docs-vitepress/scripts/generate-api.ts +0 -243
- package/core/apps/docs-vitepress/scripts/migrate-guides.ts +0 -129
- package/core/apps/docs-vitepress/tsconfig.json +0 -11
- package/core/apps/docs-vitepress/v/latest/guides/attachments-by-url.md +0 -57
- package/core/apps/docs-vitepress/v/latest/guides/attachments.md +0 -62
- package/core/apps/docs-vitepress/v/latest/guides/basic-bot.md +0 -49
- package/core/apps/docs-vitepress/v/latest/guides/channels.md +0 -180
- package/core/apps/docs-vitepress/v/latest/guides/deprecated-apis.md +0 -58
- package/core/apps/docs-vitepress/v/latest/guides/discord-js-compatibility.md +0 -42
- package/core/apps/docs-vitepress/v/latest/guides/editing-embeds.md +0 -65
- package/core/apps/docs-vitepress/v/latest/guides/embed-media.md +0 -87
- package/core/apps/docs-vitepress/v/latest/guides/embeds.md +0 -166
- package/core/apps/docs-vitepress/v/latest/guides/emojis.md +0 -77
- package/core/apps/docs-vitepress/v/latest/guides/events.md +0 -202
- package/core/apps/docs-vitepress/v/latest/guides/gifs.md +0 -47
- package/core/apps/docs-vitepress/v/latest/guides/installation.md +0 -10
- package/core/apps/docs-vitepress/v/latest/guides/moderation.md +0 -89
- package/core/apps/docs-vitepress/v/latest/guides/permissions.md +0 -130
- package/core/apps/docs-vitepress/v/latest/guides/prefix-commands.md +0 -41
- package/core/apps/docs-vitepress/v/latest/guides/profile-urls.md +0 -58
- package/core/apps/docs-vitepress/v/latest/guides/reactions.md +0 -69
- package/core/apps/docs-vitepress/v/latest/guides/roles.md +0 -130
- package/core/apps/docs-vitepress/v/latest/guides/sending-without-reply.md +0 -172
- package/core/apps/docs-vitepress/v/latest/guides/voice.md +0 -109
- package/core/apps/docs-vitepress/v/latest/guides/wait-for-guilds.md +0 -37
- package/core/apps/docs-vitepress/v/latest/guides/webhook-attachments-embeds.md +0 -73
- package/core/apps/docs-vitepress/v/latest/guides/webhooks.md +0 -131
- package/core/eslint.config.js +0 -80
- package/core/examples/.env.example +0 -22
- package/core/examples/README.md +0 -68
- package/core/examples/first-steps-bot.js +0 -118
- package/core/examples/minimal-bot.js +0 -17
- package/core/examples/moderation-bot.js +0 -209
- package/core/examples/package.json +0 -14
- package/core/examples/ping-bot.js +0 -1146
- package/core/examples/reaction-bot.js +0 -70
- package/core/examples/reaction-roles-bot.js +0 -140
- package/core/examples/webhook-bot.js +0 -239
- package/core/flux.png +0 -0
- package/core/package.json +0 -78
- package/core/packages/builders/package.json +0 -51
- package/core/packages/builders/src/index.ts +0 -13
- package/core/packages/builders/src/messages/AttachmentBuilder.test.ts +0 -79
- package/core/packages/builders/src/messages/AttachmentBuilder.ts +0 -69
- package/core/packages/builders/src/messages/EmbedBuilder.test.ts +0 -266
- package/core/packages/builders/src/messages/EmbedBuilder.ts +0 -239
- package/core/packages/builders/src/messages/MessagePayload.test.ts +0 -118
- package/core/packages/builders/src/messages/MessagePayload.ts +0 -122
- package/core/packages/builders/tsconfig.json +0 -9
- package/core/packages/builders/tsup.config.ts +0 -9
- package/core/packages/builders/vitest.config.ts +0 -9
- package/core/packages/collection/package.json +0 -47
- package/core/packages/collection/src/Collection.test.ts +0 -232
- package/core/packages/collection/src/Collection.ts +0 -196
- package/core/packages/collection/src/index.ts +0 -1
- package/core/packages/collection/tsconfig.json +0 -9
- package/core/packages/collection/tsup.config.ts +0 -9
- package/core/packages/collection/vitest.config.ts +0 -9
- package/core/packages/docgen/package.json +0 -26
- package/core/packages/docgen/src/extract.ts +0 -262
- package/core/packages/docgen/src/formatType.ts +0 -24
- package/core/packages/docgen/src/index.ts +0 -103
- package/core/packages/docgen/src/schema.ts +0 -100
- package/core/packages/docgen/src/visitor.ts +0 -147
- package/core/packages/docgen/tsconfig.json +0 -9
- package/core/packages/docgen/tsup.config.ts +0 -9
- package/core/packages/fluxer-core/README.md +0 -26
- package/core/packages/fluxer-core/package.json +0 -60
- package/core/packages/fluxer-core/src/client/ChannelManager.ts +0 -143
- package/core/packages/fluxer-core/src/client/Client.gateway.test.ts +0 -84
- package/core/packages/fluxer-core/src/client/Client.resolveEmoji.test.ts +0 -45
- package/core/packages/fluxer-core/src/client/Client.ts +0 -558
- package/core/packages/fluxer-core/src/client/ClientUser.ts +0 -40
- package/core/packages/fluxer-core/src/client/EventHandlerRegistry.ts +0 -469
- package/core/packages/fluxer-core/src/client/GuildManager.ts +0 -79
- package/core/packages/fluxer-core/src/client/GuildMemberManager.ts +0 -91
- package/core/packages/fluxer-core/src/client/MessageManager.ts +0 -58
- package/core/packages/fluxer-core/src/client/UsersManager.ts +0 -122
- package/core/packages/fluxer-core/src/errors/ErrorCodes.test.ts +0 -19
- package/core/packages/fluxer-core/src/errors/ErrorCodes.ts +0 -12
- package/core/packages/fluxer-core/src/errors/FluxerError.test.ts +0 -32
- package/core/packages/fluxer-core/src/errors/FluxerError.ts +0 -15
- package/core/packages/fluxer-core/src/index.ts +0 -85
- package/core/packages/fluxer-core/src/structures/Base.ts +0 -7
- package/core/packages/fluxer-core/src/structures/Channel.ts +0 -508
- package/core/packages/fluxer-core/src/structures/Guild.test.ts +0 -189
- package/core/packages/fluxer-core/src/structures/Guild.ts +0 -734
- package/core/packages/fluxer-core/src/structures/GuildBan.ts +0 -35
- package/core/packages/fluxer-core/src/structures/GuildEmoji.ts +0 -57
- package/core/packages/fluxer-core/src/structures/GuildMember.test.ts +0 -203
- package/core/packages/fluxer-core/src/structures/GuildMember.ts +0 -213
- package/core/packages/fluxer-core/src/structures/GuildMemberRoleManager.ts +0 -121
- package/core/packages/fluxer-core/src/structures/GuildSticker.ts +0 -56
- package/core/packages/fluxer-core/src/structures/Invite.test.ts +0 -103
- package/core/packages/fluxer-core/src/structures/Invite.ts +0 -121
- package/core/packages/fluxer-core/src/structures/Message.test.ts +0 -109
- package/core/packages/fluxer-core/src/structures/Message.ts +0 -397
- package/core/packages/fluxer-core/src/structures/MessageReaction.ts +0 -72
- package/core/packages/fluxer-core/src/structures/PartialMessage.ts +0 -12
- package/core/packages/fluxer-core/src/structures/Role.test.ts +0 -77
- package/core/packages/fluxer-core/src/structures/Role.ts +0 -112
- package/core/packages/fluxer-core/src/structures/User.test.ts +0 -110
- package/core/packages/fluxer-core/src/structures/User.ts +0 -109
- package/core/packages/fluxer-core/src/structures/Webhook.test.ts +0 -109
- package/core/packages/fluxer-core/src/structures/Webhook.ts +0 -258
- package/core/packages/fluxer-core/src/util/Constants.test.ts +0 -16
- package/core/packages/fluxer-core/src/util/Constants.ts +0 -7
- package/core/packages/fluxer-core/src/util/Events.ts +0 -46
- package/core/packages/fluxer-core/src/util/MessageCollector.ts +0 -87
- package/core/packages/fluxer-core/src/util/Options.ts +0 -33
- package/core/packages/fluxer-core/src/util/ReactionCollector.ts +0 -116
- package/core/packages/fluxer-core/src/util/cdn.test.ts +0 -108
- package/core/packages/fluxer-core/src/util/cdn.ts +0 -130
- package/core/packages/fluxer-core/src/util/guildUtils.ts +0 -33
- package/core/packages/fluxer-core/src/util/messageUtils.test.ts +0 -74
- package/core/packages/fluxer-core/src/util/messageUtils.ts +0 -119
- package/core/packages/fluxer-core/src/util/permissions.test.ts +0 -95
- package/core/packages/fluxer-core/src/util/permissions.ts +0 -43
- package/core/packages/fluxer-core/tsconfig.json +0 -9
- package/core/packages/fluxer-core/tsup.config.ts +0 -9
- package/core/packages/fluxer-core/vitest.config.ts +0 -9
- package/core/packages/rest/package.json +0 -52
- package/core/packages/rest/src/REST.test.ts +0 -64
- package/core/packages/rest/src/REST.ts +0 -90
- package/core/packages/rest/src/RateLimitManager.test.ts +0 -71
- package/core/packages/rest/src/RateLimitManager.ts +0 -60
- package/core/packages/rest/src/RequestManager.test.ts +0 -87
- package/core/packages/rest/src/RequestManager.ts +0 -172
- package/core/packages/rest/src/errors/FluxerAPIError.test.ts +0 -57
- package/core/packages/rest/src/errors/FluxerAPIError.ts +0 -21
- package/core/packages/rest/src/errors/HTTPError.test.ts +0 -55
- package/core/packages/rest/src/errors/HTTPError.ts +0 -25
- package/core/packages/rest/src/errors/RateLimitError.test.ts +0 -41
- package/core/packages/rest/src/errors/RateLimitError.ts +0 -15
- package/core/packages/rest/src/errors/index.ts +0 -3
- package/core/packages/rest/src/index.ts +0 -6
- package/core/packages/rest/src/utils/constants.test.ts +0 -31
- package/core/packages/rest/src/utils/constants.ts +0 -5
- package/core/packages/rest/src/utils/files.test.ts +0 -37
- package/core/packages/rest/src/utils/files.ts +0 -75
- package/core/packages/rest/tsconfig.json +0 -9
- package/core/packages/rest/tsup.config.ts +0 -9
- package/core/packages/rest/vitest.config.ts +0 -9
- package/core/packages/types/package.json +0 -46
- package/core/packages/types/src/api/ban.ts +0 -8
- package/core/packages/types/src/api/channel.ts +0 -65
- package/core/packages/types/src/api/embed.ts +0 -82
- package/core/packages/types/src/api/emoji.ts +0 -12
- package/core/packages/types/src/api/errors.ts +0 -68
- package/core/packages/types/src/api/gateway.ts +0 -14
- package/core/packages/types/src/api/guild.ts +0 -123
- package/core/packages/types/src/api/index.ts +0 -15
- package/core/packages/types/src/api/instance.ts +0 -32
- package/core/packages/types/src/api/interaction.ts +0 -26
- package/core/packages/types/src/api/invite.ts +0 -28
- package/core/packages/types/src/api/message.ts +0 -140
- package/core/packages/types/src/api/role.ts +0 -41
- package/core/packages/types/src/api/sticker.ts +0 -14
- package/core/packages/types/src/api/user.ts +0 -79
- package/core/packages/types/src/api/webhook.ts +0 -41
- package/core/packages/types/src/common/index.ts +0 -1
- package/core/packages/types/src/common/snowflake.test.ts +0 -9
- package/core/packages/types/src/common/snowflake.ts +0 -8
- package/core/packages/types/src/gateway/events.ts +0 -189
- package/core/packages/types/src/gateway/index.ts +0 -3
- package/core/packages/types/src/gateway/opcodes.ts +0 -17
- package/core/packages/types/src/gateway/payloads.ts +0 -481
- package/core/packages/types/src/index.ts +0 -4
- package/core/packages/types/src/rest/index.ts +0 -1
- package/core/packages/types/src/rest/routes.test.ts +0 -169
- package/core/packages/types/src/rest/routes.ts +0 -109
- package/core/packages/types/tsconfig.json +0 -9
- package/core/packages/types/tsup.config.ts +0 -9
- package/core/packages/types/vitest.config.ts +0 -9
- package/core/packages/util/package.json +0 -51
- package/core/packages/util/src/BitField.test.ts +0 -96
- package/core/packages/util/src/BitField.ts +0 -105
- package/core/packages/util/src/MessageFlagsBitField.test.ts +0 -42
- package/core/packages/util/src/MessageFlagsBitField.ts +0 -20
- package/core/packages/util/src/PermissionsBitField.test.ts +0 -79
- package/core/packages/util/src/PermissionsBitField.ts +0 -97
- package/core/packages/util/src/SnowflakeUtil.test.ts +0 -69
- package/core/packages/util/src/SnowflakeUtil.ts +0 -65
- package/core/packages/util/src/UserFlagsBitField.test.ts +0 -39
- package/core/packages/util/src/UserFlagsBitField.ts +0 -48
- package/core/packages/util/src/deprecation.test.ts +0 -44
- package/core/packages/util/src/deprecation.ts +0 -28
- package/core/packages/util/src/emojiShortcodes.generated.ts +0 -5
- package/core/packages/util/src/emojiShortcodes.test.ts +0 -41
- package/core/packages/util/src/emojiShortcodes.ts +0 -22
- package/core/packages/util/src/formatters.test.ts +0 -65
- package/core/packages/util/src/formatters.ts +0 -35
- package/core/packages/util/src/index.ts +0 -34
- package/core/packages/util/src/resolvers.test.ts +0 -198
- package/core/packages/util/src/resolvers.ts +0 -127
- package/core/packages/util/src/tenorUtils.test.ts +0 -75
- package/core/packages/util/src/tenorUtils.ts +0 -86
- package/core/packages/util/tsconfig.json +0 -9
- package/core/packages/util/tsup.config.ts +0 -9
- package/core/packages/util/vitest.config.ts +0 -9
- package/core/packages/voice/README.md +0 -42
- package/core/packages/voice/package.json +0 -67
- package/core/packages/voice/src/LiveKitRtcConnection.receive.test.ts +0 -24
- package/core/packages/voice/src/LiveKitRtcConnection.ts +0 -1767
- package/core/packages/voice/src/VoiceConnection.ts +0 -413
- package/core/packages/voice/src/VoiceManager.receive.test.ts +0 -61
- package/core/packages/voice/src/VoiceManager.test.ts +0 -44
- package/core/packages/voice/src/VoiceManager.ts +0 -503
- package/core/packages/voice/src/exports.test.ts +0 -38
- package/core/packages/voice/src/index.ts +0 -51
- package/core/packages/voice/src/livekit.test.ts +0 -48
- package/core/packages/voice/src/livekit.ts +0 -33
- package/core/packages/voice/src/mp4box.d.ts +0 -32
- package/core/packages/voice/src/opusUtils.test.ts +0 -29
- package/core/packages/voice/src/opusUtils.ts +0 -86
- package/core/packages/voice/src/streamPreviewPlaceholder.test.ts +0 -16
- package/core/packages/voice/src/streamPreviewPlaceholder.ts +0 -8
- package/core/packages/voice/src/ws.d.ts +0 -1
- package/core/packages/voice/tsconfig.json +0 -5
- package/core/packages/voice/tsup.config.ts +0 -10
- package/core/packages/voice/vitest.config.ts +0 -9
- package/core/packages/ws/package.json +0 -52
- package/core/packages/ws/src/WebSocketManager.ts +0 -130
- package/core/packages/ws/src/WebSocketShard.ts +0 -296
- package/core/packages/ws/src/index.ts +0 -12
- package/core/packages/ws/src/utils/constants.test.ts +0 -46
- package/core/packages/ws/src/utils/constants.ts +0 -22
- package/core/packages/ws/src/utils/getWebSocket.ts +0 -55
- package/core/packages/ws/src/ws.d.ts +0 -10
- package/core/packages/ws/tsconfig.json +0 -9
- package/core/packages/ws/tsup.config.ts +0 -9
- package/core/pnpm-lock.yaml +0 -7033
- package/core/pnpm-workspace.yaml +0 -4
- package/core/scripts/generate-ai-rag.ts +0 -240
- package/core/scripts/generate-docs.ts +0 -143
- package/core/scripts/generate-emoji-shortcodes.ts +0 -58
- package/core/scripts/generate-types.ts +0 -6
- package/core/scripts/publish-ordered.js +0 -63
- package/core/scripts/test-cjs-require.mjs +0 -43
- package/core/scripts/test-esm-imports.mjs +0 -42
- package/core/scripts/test-package-exports.mjs +0 -98
- package/core/scripts/test-smoke.mjs +0 -103
- package/core/tsconfig.json +0 -18
- package/core/turbo.json +0 -30
- package/core/vitest.config.ts +0 -17
- package/core/wrangler.jsonc +0 -9
package/package.json
CHANGED
|
@@ -1,26 +1,61 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@erinjs/core",
|
|
3
|
-
"
|
|
4
|
-
|
|
3
|
+
"publishConfig": {
|
|
4
|
+
"access": "public"
|
|
5
|
+
},
|
|
6
|
+
"version": "1.2.4",
|
|
7
|
+
"description": "A fully-featured SDK for Fluxer bots",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "https://github.com/blstmo-abandoned-us-for-the-milk/core.git",
|
|
11
|
+
"directory": "packages/fluxer-core"
|
|
12
|
+
},
|
|
13
|
+
"bugs": "https://github.com/blstmo-abandoned-us-for-the-milk/core/issues",
|
|
14
|
+
"homepage": "https://github.com/blstmo-abandoned-us-for-the-milk/core#readme",
|
|
5
15
|
"keywords": [
|
|
6
16
|
"fluxer",
|
|
7
|
-
"
|
|
17
|
+
"discord",
|
|
8
18
|
"sdk",
|
|
19
|
+
"bot",
|
|
9
20
|
"api"
|
|
10
21
|
],
|
|
11
|
-
"
|
|
12
|
-
"
|
|
13
|
-
|
|
22
|
+
"license": "Apache-2.0",
|
|
23
|
+
"main": "./dist/index.js",
|
|
24
|
+
"module": "./dist/index.mjs",
|
|
25
|
+
"types": "./dist/index.d.ts",
|
|
26
|
+
"exports": {
|
|
27
|
+
".": {
|
|
28
|
+
"types": "./dist/index.d.ts",
|
|
29
|
+
"import": "./dist/index.mjs",
|
|
30
|
+
"require": "./dist/index.js"
|
|
31
|
+
}
|
|
14
32
|
},
|
|
15
|
-
"
|
|
16
|
-
"
|
|
17
|
-
|
|
33
|
+
"files": [
|
|
34
|
+
"dist"
|
|
35
|
+
],
|
|
36
|
+
"dependencies": {
|
|
37
|
+
"@erinjs/rest": "1.2.4",
|
|
38
|
+
"@erinjs/ws": "1.2.4",
|
|
39
|
+
"@erinjs/builders": "1.2.4",
|
|
40
|
+
"@erinjs/collection": "1.2.4",
|
|
41
|
+
"@erinjs/util": "1.2.4",
|
|
42
|
+
"@erinjs/types": "1.2.4"
|
|
43
|
+
},
|
|
44
|
+
"devDependencies": {
|
|
45
|
+
"@types/node": "^20.0.0",
|
|
46
|
+
"tsup": "^8.3.0",
|
|
47
|
+
"typescript": "^5.6.0"
|
|
48
|
+
},
|
|
49
|
+
"engines": {
|
|
50
|
+
"node": ">=18.0.0"
|
|
18
51
|
},
|
|
19
|
-
"license": "Apache-2.0",
|
|
20
|
-
"author": "vesaber, dogbone",
|
|
21
|
-
"type": "ESM",
|
|
22
|
-
"main": "index.js",
|
|
23
52
|
"scripts": {
|
|
24
|
-
"
|
|
53
|
+
"build": "tsup",
|
|
54
|
+
"clean": "rm -rf dist",
|
|
55
|
+
"lint": "eslint src --max-warnings 0 --config ../../eslint.config.js",
|
|
56
|
+
"lint:fix": "eslint src --fix --config ../../eslint.config.js",
|
|
57
|
+
"typecheck": "tsc --noEmit -p tsconfig.json",
|
|
58
|
+
"test": "pnpm run typecheck && vitest run --passWithNoTests",
|
|
59
|
+
"test:coverage": "vitest run --coverage"
|
|
25
60
|
}
|
|
26
|
-
}
|
|
61
|
+
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
# Changesets
|
|
2
|
-
|
|
3
|
-
Hello and welcome! This folder has been automatically generated by `@changesets/cli`, a build tool that works
|
|
4
|
-
with multi-package repos, or single-package repos to help you version and publish your code. You can
|
|
5
|
-
find the full documentation for it [in our repository](https://github.com/changesets/changesets)
|
|
6
|
-
|
|
7
|
-
We have a quick list of common questions to get you started engaging with this project in
|
|
8
|
-
[our documentation](https://github.com/changesets/changesets/blob/main/docs/common-questions.md)
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
'@erinjs/builders': patch
|
|
3
|
-
'@erinjs/collection': patch
|
|
4
|
-
'@erinjs/core': patch
|
|
5
|
-
'@erinjs/rest': patch
|
|
6
|
-
'@erinjs/types': patch
|
|
7
|
-
'@erinjs/util': patch
|
|
8
|
-
'@erinjs/voice': patch
|
|
9
|
-
'@erinjs/ws': patch
|
|
10
|
-
---
|
|
11
|
-
|
|
12
|
-
chore(release): bootstrap @erinjs prerelease packages
|
|
13
|
-
|
|
14
|
-
Initial prerelease for the @erinjs package line.
|
|
15
|
-
|
|
16
|
-
Publishes the current SDK packages under @erinjs with the community prerelease
|
|
17
|
-
tag. Runtime APIs and package exports stay the same.
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://unpkg.com/@changesets/config@3.1.2/schema.json",
|
|
3
|
-
"changelog": "./no-changelog.js",
|
|
4
|
-
"commit": false,
|
|
5
|
-
"fixed": [],
|
|
6
|
-
"linked": [],
|
|
7
|
-
"access": "public",
|
|
8
|
-
"baseBranch": "main",
|
|
9
|
-
"updateInternalDependencies": "patch",
|
|
10
|
-
"ignore": []
|
|
11
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* No-op changelog. Changelog is maintained in apps/docs/src/data/changelog.ts
|
|
3
|
-
* as the single source of truth for the docs site.
|
|
4
|
-
*/
|
|
5
|
-
async function getReleaseLine() {
|
|
6
|
-
return '';
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
async function getDependencyReleaseLine() {
|
|
10
|
-
return '';
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
module.exports = {
|
|
14
|
-
getReleaseLine,
|
|
15
|
-
getDependencyReleaseLine,
|
|
16
|
-
};
|
package/core/.changeset/pre.json
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"mode": "pre",
|
|
3
|
-
"tag": "community",
|
|
4
|
-
"initialVersions": {
|
|
5
|
-
"@erinjs/builders": "1.2.4",
|
|
6
|
-
"@erinjs/collection": "1.2.4",
|
|
7
|
-
"@erinjs/core": "1.2.4",
|
|
8
|
-
"@erinjs/docgen": "1.2.4",
|
|
9
|
-
"@erinjs/docs": "1.2.4",
|
|
10
|
-
"@erinjs/rest": "1.2.4",
|
|
11
|
-
"@erinjs/types": "1.2.4",
|
|
12
|
-
"@erinjs/util": "1.2.4",
|
|
13
|
-
"@erinjs/voice": "1.2.4",
|
|
14
|
-
"@erinjs/ws": "1.2.4"
|
|
15
|
-
},
|
|
16
|
-
"changesets": []
|
|
17
|
-
}
|
package/core/.editorconfig
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
# EditorConfig - https://editorconfig.org
|
|
2
|
-
root = true
|
|
3
|
-
|
|
4
|
-
[*]
|
|
5
|
-
indent_style = space
|
|
6
|
-
indent_size = 2
|
|
7
|
-
end_of_line = lf
|
|
8
|
-
charset = utf-8
|
|
9
|
-
trim_trailing_whitespace = true
|
|
10
|
-
insert_final_newline = true
|
|
11
|
-
|
|
12
|
-
[*.md]
|
|
13
|
-
trim_trailing_whitespace = false
|
package/core/.gitattributes
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
# Code of Conduct
|
|
2
|
-
|
|
3
|
-
## Our Pledge
|
|
4
|
-
|
|
5
|
-
We pledge to make participation in our project a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
|
|
6
|
-
|
|
7
|
-
## Our Standards
|
|
8
|
-
|
|
9
|
-
- Be respectful and inclusive
|
|
10
|
-
- Accept constructive criticism gracefully
|
|
11
|
-
- Focus on what is best for the community
|
|
12
|
-
- Show empathy toward other community members
|
|
13
|
-
|
|
14
|
-
## Unacceptable Behavior
|
|
15
|
-
|
|
16
|
-
- Trolling, insulting or derogatory comments
|
|
17
|
-
- Public or private harassment
|
|
18
|
-
- Publishing others' private information without permission
|
|
19
|
-
- Other conduct which could reasonably be considered inappropriate
|
|
20
|
-
|
|
21
|
-
## Enforcement
|
|
22
|
-
|
|
23
|
-
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct.
|
package/core/.github/FUNDING.yml
DELETED
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: Bug report
|
|
3
|
-
about: Create a report to help us improve
|
|
4
|
-
title: '[BUG] '
|
|
5
|
-
labels: bug
|
|
6
|
-
assignees: ''
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
## Describe the bug
|
|
10
|
-
|
|
11
|
-
A clear and concise description of what the bug is.
|
|
12
|
-
|
|
13
|
-
## To Reproduce
|
|
14
|
-
|
|
15
|
-
1. ...
|
|
16
|
-
2. ...
|
|
17
|
-
3. ...
|
|
18
|
-
|
|
19
|
-
## Expected behavior
|
|
20
|
-
|
|
21
|
-
What you expected to happen.
|
|
22
|
-
|
|
23
|
-
## Environment
|
|
24
|
-
|
|
25
|
-
- @erinjs/core version:
|
|
26
|
-
- Node.js version:
|
|
27
|
-
- OS:
|
|
28
|
-
|
|
29
|
-
## Additional context
|
|
30
|
-
|
|
31
|
-
Add any other context about the problem here.
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: Feature request
|
|
3
|
-
about: Suggest an idea for this project
|
|
4
|
-
title: '[FEATURE] '
|
|
5
|
-
labels: enhancement
|
|
6
|
-
assignees: ''
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
## Problem
|
|
10
|
-
|
|
11
|
-
A clear and concise description of what the problem is.
|
|
12
|
-
|
|
13
|
-
## Proposed solution
|
|
14
|
-
|
|
15
|
-
A clear and concise description of what you want to happen.
|
|
16
|
-
|
|
17
|
-
## Alternatives considered
|
|
18
|
-
|
|
19
|
-
Any alternative solutions or features you've considered.
|
|
20
|
-
|
|
21
|
-
## Additional context
|
|
22
|
-
|
|
23
|
-
Add any other context about the feature request here.
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
## Description
|
|
2
|
-
|
|
3
|
-
<!-- Describe your changes -->
|
|
4
|
-
|
|
5
|
-
## Type of change
|
|
6
|
-
|
|
7
|
-
- [ ] Bug fix
|
|
8
|
-
- [ ] New feature
|
|
9
|
-
- [ ] Breaking change
|
|
10
|
-
- [ ] Documentation update
|
|
11
|
-
|
|
12
|
-
## Checklist
|
|
13
|
-
|
|
14
|
-
- [ ] My code follows the project's style guidelines (run `pnpm run lint`)
|
|
15
|
-
- [ ] I have run `pnpm run build` successfully
|
|
16
|
-
- [ ] I have run `pnpm run test` successfully
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
version: 2
|
|
2
|
-
updates:
|
|
3
|
-
- package-ecosystem: npm
|
|
4
|
-
directory: /
|
|
5
|
-
schedule:
|
|
6
|
-
interval: weekly
|
|
7
|
-
day: monday
|
|
8
|
-
open-pull-requests-limit: 5
|
|
9
|
-
groups:
|
|
10
|
-
typescript-eslint:
|
|
11
|
-
patterns:
|
|
12
|
-
- '@typescript-eslint/*'
|
|
13
|
-
vitest:
|
|
14
|
-
patterns:
|
|
15
|
-
- 'vitest'
|
|
16
|
-
- '@vitest/*'
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
name: Auto Approve
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
pull_request_target:
|
|
5
|
-
types: [opened, synchronize, reopened]
|
|
6
|
-
|
|
7
|
-
jobs:
|
|
8
|
-
auto-approve:
|
|
9
|
-
runs-on: ubuntu-latest
|
|
10
|
-
permissions:
|
|
11
|
-
pull-requests: write
|
|
12
|
-
if: ${{ github.event.pull_request.author_association == 'MEMBER' || github.event.pull_request.author_association == 'OWNER' }}
|
|
13
|
-
|
|
14
|
-
steps:
|
|
15
|
-
- uses: hmarr/auto-approve-action@v4
|
|
16
|
-
continue-on-error: true
|
|
@@ -1,187 +0,0 @@
|
|
|
1
|
-
name: CI
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches: [main]
|
|
6
|
-
pull_request:
|
|
7
|
-
branches: [main]
|
|
8
|
-
|
|
9
|
-
concurrency:
|
|
10
|
-
group: ${{ github.workflow }}-${{ github.ref }}
|
|
11
|
-
cancel-in-progress: true
|
|
12
|
-
|
|
13
|
-
jobs:
|
|
14
|
-
format:
|
|
15
|
-
runs-on: ubuntu-latest
|
|
16
|
-
permissions:
|
|
17
|
-
contents: write
|
|
18
|
-
issues: write
|
|
19
|
-
pull-requests: write
|
|
20
|
-
steps:
|
|
21
|
-
- uses: actions/checkout@v4
|
|
22
|
-
with:
|
|
23
|
-
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
|
|
24
|
-
token: ${{ secrets.GITHUB_TOKEN }}
|
|
25
|
-
|
|
26
|
-
- uses: pnpm/action-setup@v4
|
|
27
|
-
|
|
28
|
-
- uses: actions/setup-node@v4
|
|
29
|
-
with:
|
|
30
|
-
node-version: '20'
|
|
31
|
-
cache: 'pnpm'
|
|
32
|
-
|
|
33
|
-
- name: Install dependencies
|
|
34
|
-
run: pnpm install --ignore-scripts
|
|
35
|
-
|
|
36
|
-
- name: Format
|
|
37
|
-
run: pnpm run format
|
|
38
|
-
|
|
39
|
-
- name: Check for format changes
|
|
40
|
-
id: format_check
|
|
41
|
-
run: |
|
|
42
|
-
git add -A
|
|
43
|
-
if [ -n "$(git status --porcelain)" ]; then
|
|
44
|
-
echo "has_changes=true" >> $GITHUB_OUTPUT
|
|
45
|
-
else
|
|
46
|
-
echo "has_changes=false" >> $GITHUB_OUTPUT
|
|
47
|
-
fi
|
|
48
|
-
|
|
49
|
-
- name: Commit and push format fixes
|
|
50
|
-
if: ${{ steps.format_check.outputs.has_changes == 'true' && github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name == github.repository }}
|
|
51
|
-
run: |
|
|
52
|
-
git config user.name "github-actions[bot]"
|
|
53
|
-
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
54
|
-
git commit -m "style: apply prettier"
|
|
55
|
-
git push origin HEAD:${{ github.event.pull_request.head.ref }}
|
|
56
|
-
|
|
57
|
-
- name: Comment on fork PR about format fixes
|
|
58
|
-
if: ${{ steps.format_check.outputs.has_changes == 'true' && github.event_name == 'pull_request' && github.event.pull_request.head.repo.full_name != github.repository }}
|
|
59
|
-
continue-on-error: true
|
|
60
|
-
uses: actions/github-script@v7
|
|
61
|
-
with:
|
|
62
|
-
script: |
|
|
63
|
-
const body = '## Prettier format needed\n\nThis PR has formatting issues that CI cannot auto-fix (PRs from forks cannot be pushed to). Please run:\n\n```bash\npnpm run format\n```\n\nThen commit and push the changes.\n\n<!-- prettier-format-comment -->';
|
|
64
|
-
const { data: comments } = await github.rest.issues.listComments({
|
|
65
|
-
owner: context.repo.owner,
|
|
66
|
-
repo: context.repo.repo,
|
|
67
|
-
issue_number: context.issue.number,
|
|
68
|
-
});
|
|
69
|
-
const botComment = comments.find(c => c.body && c.body.includes('<!-- prettier-format-comment -->'));
|
|
70
|
-
if (botComment) {
|
|
71
|
-
await github.rest.issues.updateComment({
|
|
72
|
-
owner: context.repo.owner,
|
|
73
|
-
repo: context.repo.repo,
|
|
74
|
-
comment_id: botComment.id,
|
|
75
|
-
body,
|
|
76
|
-
});
|
|
77
|
-
} else {
|
|
78
|
-
await github.rest.issues.createComment({
|
|
79
|
-
owner: context.repo.owner,
|
|
80
|
-
repo: context.repo.repo,
|
|
81
|
-
issue_number: context.issue.number,
|
|
82
|
-
body,
|
|
83
|
-
});
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
lint:
|
|
87
|
-
runs-on: ubuntu-latest
|
|
88
|
-
needs: format
|
|
89
|
-
steps:
|
|
90
|
-
- uses: actions/checkout@v4
|
|
91
|
-
with:
|
|
92
|
-
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
|
|
93
|
-
|
|
94
|
-
- uses: pnpm/action-setup@v4
|
|
95
|
-
|
|
96
|
-
- uses: actions/setup-node@v4
|
|
97
|
-
with:
|
|
98
|
-
node-version: '20'
|
|
99
|
-
cache: 'pnpm'
|
|
100
|
-
|
|
101
|
-
- name: Install dependencies
|
|
102
|
-
run: pnpm install --ignore-scripts
|
|
103
|
-
|
|
104
|
-
- name: Lint
|
|
105
|
-
run: pnpm run lint
|
|
106
|
-
|
|
107
|
-
build-test:
|
|
108
|
-
runs-on: ubuntu-latest
|
|
109
|
-
needs: format
|
|
110
|
-
permissions:
|
|
111
|
-
contents: read
|
|
112
|
-
checks: write
|
|
113
|
-
steps:
|
|
114
|
-
- uses: actions/checkout@v4
|
|
115
|
-
with:
|
|
116
|
-
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
|
|
117
|
-
|
|
118
|
-
- uses: pnpm/action-setup@v4
|
|
119
|
-
|
|
120
|
-
- uses: actions/setup-node@v4
|
|
121
|
-
with:
|
|
122
|
-
node-version: '20'
|
|
123
|
-
cache: 'pnpm'
|
|
124
|
-
|
|
125
|
-
- name: Install dependencies
|
|
126
|
-
run: pnpm install --ignore-scripts
|
|
127
|
-
|
|
128
|
-
- name: Test (all unit tests, load tests, smoke tests)
|
|
129
|
-
run: pnpm run test:all
|
|
130
|
-
|
|
131
|
-
- name: Publish test results
|
|
132
|
-
if: always() && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository)
|
|
133
|
-
uses: dorny/test-reporter@v1
|
|
134
|
-
with:
|
|
135
|
-
name: Vitest
|
|
136
|
-
path: test-results/junit.xml
|
|
137
|
-
reporter: java-junit
|
|
138
|
-
fail-on-error: false
|
|
139
|
-
|
|
140
|
-
coverage:
|
|
141
|
-
runs-on: ubuntu-latest
|
|
142
|
-
needs: format
|
|
143
|
-
steps:
|
|
144
|
-
- uses: actions/checkout@v4
|
|
145
|
-
with:
|
|
146
|
-
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.ref }}
|
|
147
|
-
|
|
148
|
-
- uses: pnpm/action-setup@v4
|
|
149
|
-
|
|
150
|
-
- uses: actions/setup-node@v4
|
|
151
|
-
with:
|
|
152
|
-
node-version: '20'
|
|
153
|
-
cache: 'pnpm'
|
|
154
|
-
|
|
155
|
-
- name: Install dependencies
|
|
156
|
-
run: pnpm install --ignore-scripts
|
|
157
|
-
|
|
158
|
-
- name: Build
|
|
159
|
-
run: pnpm run build --concurrency=10
|
|
160
|
-
|
|
161
|
-
- name: Test coverage
|
|
162
|
-
run: pnpm run test:coverage
|
|
163
|
-
|
|
164
|
-
- name: Upload coverage to Codecov
|
|
165
|
-
uses: codecov/codecov-action@v4
|
|
166
|
-
with:
|
|
167
|
-
files: coverage/lcov.info
|
|
168
|
-
fail_ci_if_error: false
|
|
169
|
-
|
|
170
|
-
audit:
|
|
171
|
-
runs-on: ubuntu-latest
|
|
172
|
-
needs: format
|
|
173
|
-
steps:
|
|
174
|
-
- uses: actions/checkout@v4
|
|
175
|
-
|
|
176
|
-
- uses: pnpm/action-setup@v4
|
|
177
|
-
|
|
178
|
-
- uses: actions/setup-node@v4
|
|
179
|
-
with:
|
|
180
|
-
node-version: '20'
|
|
181
|
-
cache: 'pnpm'
|
|
182
|
-
|
|
183
|
-
- name: Install dependencies
|
|
184
|
-
run: pnpm install --ignore-scripts
|
|
185
|
-
|
|
186
|
-
- name: Audit
|
|
187
|
-
run: pnpm audit --prod
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
name: CodeQL
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches: [main]
|
|
6
|
-
pull_request:
|
|
7
|
-
branches: [main]
|
|
8
|
-
schedule:
|
|
9
|
-
- cron: '0 0 * * 1'
|
|
10
|
-
|
|
11
|
-
jobs:
|
|
12
|
-
analyze:
|
|
13
|
-
runs-on: ubuntu-latest
|
|
14
|
-
permissions:
|
|
15
|
-
security-events: write
|
|
16
|
-
actions: read
|
|
17
|
-
contents: read
|
|
18
|
-
steps:
|
|
19
|
-
- uses: actions/checkout@v4
|
|
20
|
-
|
|
21
|
-
- name: Initialize CodeQL
|
|
22
|
-
uses: github/codeql-action/init@v3
|
|
23
|
-
with:
|
|
24
|
-
languages: javascript-typescript
|
|
25
|
-
|
|
26
|
-
- name: Autobuild
|
|
27
|
-
uses: github/codeql-action/autobuild@v3
|
|
28
|
-
|
|
29
|
-
- name: Perform CodeQL Analysis
|
|
30
|
-
uses: github/codeql-action/analyze@v3
|
|
@@ -1,54 +0,0 @@
|
|
|
1
|
-
name: Deploy docs to blstmo-abandoned-us-for-the-milk/docs
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches: [main]
|
|
6
|
-
paths:
|
|
7
|
-
- 'apps/docs-vitepress/**'
|
|
8
|
-
workflow_dispatch:
|
|
9
|
-
|
|
10
|
-
permissions:
|
|
11
|
-
contents: read
|
|
12
|
-
|
|
13
|
-
jobs:
|
|
14
|
-
deploy:
|
|
15
|
-
runs-on: ubuntu-latest
|
|
16
|
-
steps:
|
|
17
|
-
- uses: actions/checkout@v4
|
|
18
|
-
|
|
19
|
-
- name: Generate GitHub App token
|
|
20
|
-
id: app-token
|
|
21
|
-
uses: actions/create-github-app-token@v1
|
|
22
|
-
with:
|
|
23
|
-
app-id: ${{ secrets.DOCS_APP_ID }}
|
|
24
|
-
private-key: ${{ secrets.DOCS_APP_PRIVATE_KEY }}
|
|
25
|
-
owner: blstmo-abandoned-us-for-the-milk
|
|
26
|
-
repositories: docs
|
|
27
|
-
|
|
28
|
-
- uses: pnpm/action-setup@v4
|
|
29
|
-
|
|
30
|
-
- uses: actions/setup-node@v4
|
|
31
|
-
with:
|
|
32
|
-
node-version: '20'
|
|
33
|
-
cache: 'pnpm'
|
|
34
|
-
|
|
35
|
-
- name: Install dependencies
|
|
36
|
-
run: pnpm install --frozen-lockfile
|
|
37
|
-
|
|
38
|
-
- name: Generate API docs
|
|
39
|
-
working-directory: apps/docs-vitepress
|
|
40
|
-
run: node --import tsx/esm scripts/generate-api.ts api-data/latest/main.json
|
|
41
|
-
|
|
42
|
-
- name: Build VitePress
|
|
43
|
-
working-directory: apps/docs-vitepress
|
|
44
|
-
run: npx vitepress build
|
|
45
|
-
env:
|
|
46
|
-
VITEPRESS_BASE: /
|
|
47
|
-
|
|
48
|
-
- name: Deploy to docs gh-pages
|
|
49
|
-
uses: peaceiris/actions-gh-pages@v4
|
|
50
|
-
with:
|
|
51
|
-
personal_token: ${{ steps.app-token.outputs.token }}
|
|
52
|
-
external_repository: blstmo-abandoned-us-for-the-milk/docs
|
|
53
|
-
publish_branch: gh-pages
|
|
54
|
-
publish_dir: apps/docs-vitepress/.vitepress/dist
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
name: Release
|
|
2
|
-
|
|
3
|
-
on:
|
|
4
|
-
push:
|
|
5
|
-
branches: [main]
|
|
6
|
-
workflow_dispatch:
|
|
7
|
-
|
|
8
|
-
jobs:
|
|
9
|
-
release:
|
|
10
|
-
if: ${{ vars.ERINJS_RELEASE_ENABLED == 'true' }}
|
|
11
|
-
runs-on: ubuntu-latest
|
|
12
|
-
permissions:
|
|
13
|
-
contents: write
|
|
14
|
-
pull-requests: write
|
|
15
|
-
id-token: write
|
|
16
|
-
steps:
|
|
17
|
-
- uses: actions/checkout@v4
|
|
18
|
-
|
|
19
|
-
- uses: pnpm/action-setup@v4
|
|
20
|
-
|
|
21
|
-
- uses: actions/setup-node@v4
|
|
22
|
-
with:
|
|
23
|
-
node-version: '20'
|
|
24
|
-
cache: 'pnpm'
|
|
25
|
-
registry-url: 'https://registry.npmjs.org'
|
|
26
|
-
|
|
27
|
-
- name: Install dependencies
|
|
28
|
-
run: pnpm install --frozen-lockfile --ignore-scripts
|
|
29
|
-
|
|
30
|
-
- name: Test (all)
|
|
31
|
-
run: pnpm run test:all
|
|
32
|
-
|
|
33
|
-
- name: Create release PR or publish
|
|
34
|
-
uses: changesets/action@v1
|
|
35
|
-
with:
|
|
36
|
-
version: pnpm exec changeset version
|
|
37
|
-
publish: pnpm exec changeset publish
|
|
38
|
-
commit: 'chore: version packages'
|
|
39
|
-
title: 'chore: version packages'
|
|
40
|
-
env:
|
|
41
|
-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
42
|
-
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
|
|
43
|
-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
package/core/.lintstagedrc.json
DELETED
package/core/.nvmrc
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
20
|
package/core/.prettierignore
DELETED