Skip to content

Commit

Permalink
initial testing the plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
daniwasonline committed May 19, 2024
1 parent c83818c commit ca865d1
Show file tree
Hide file tree
Showing 5 changed files with 41 additions and 2 deletions.
7 changes: 6 additions & 1 deletion .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,15 @@ APPLICATION_ID=123456789012345678
## Usually, env#NODE_ENV is either one of PRODUCTION, DEVELOPMENT, or STAGING.
NODE_ENV=DEVELOPMENT

# These keys are used for developer mode and debugging.
# These keys are used for developer mode and debugging. These keys are only used when env#NODE_ENV is set to DEVELOPMENT.
## Commands and actions will be directly deployed to this guild.
DEV_GUILD=123456789012345678
## This snowflake responds to a role that the bot will use as a gatekeeper for development-only commands.
DEV_UNLOCK_ROLE=123456789012345678

## This token corresponds to a GitHub fine-grained PAT. Preferably, the PAT should belong to a bot account. This is used for certain tools, i.e. release-it.
GITHUB_TOKEN=

# !! Database (k/V)

# A Valkey (Redis OSS)-compatible key/value store is required to run SpongeChat 2.
Expand Down
23 changes: 23 additions & 0 deletions .release-it.cjs
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
module.exports = {
git: {
commitMessage: "🔖 bump: release v${version}",
requireCleanWorkingDir: false,
},
github: {
release: true,
draft: true,
web: true,
releaseName: "{version}: ",
autoGenerate: true,
},
npm: {
publish: false,
},
plugins: {
"./ci/release-it/plugin.js": {
accountId: process.env.CLOUDFLARE_ACCOUNT_ID,
token: process.env.CLOUDFLARE_ACCOUNT_TOKEN,
defaultModel: "@cf/meta/llama-3-8b-instruct",
},
},
};
Binary file modified bun.lockb
Binary file not shown.
10 changes: 10 additions & 0 deletions ci/release-it/plugin.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import { Plugin } from "release-it";
import { WorkersAI } from "../../src/util/models/index.js";
class SpongeChatReleaseItPlugin extends Plugin {
async bump(version) {
console.log(this.config, this.getContext());
throw "a";
}
}

export default SpongeChatReleaseItPlugin;
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@
"eslint": "^8.53.0",
"eslint-config-neon": "^0.1.57",
"eslint-formatter-pretty": "^5.0.0",
"prettier": "^3.0.3"
"prettier": "^3.0.3",
"release-it": "^17"
}
}

0 comments on commit ca865d1

Please sign in to comment.