cullit 1.0.0 → 1.5.0

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 (2) hide show
  1. package/dist/index.js +25 -2
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -47,11 +47,12 @@ var HELP = `
47
47
  --from, -f Start ref, JQL query, or Linear filter
48
48
  --to, -t End ref (defaults to HEAD)
49
49
  --config, -c Path to config file (default: .cullit.yml)
50
- --format Output format: markdown, html, json (default: markdown)
50
+ --format Output format: markdown, html, html-dark, html-minimal, html-edgy, json
51
51
  --dry-run Generate but don't publish
52
52
  --provider Override AI provider (anthropic, openai, gemini, ollama, openclaw, none)
53
53
  --source Override source type (local, jira, linear, gitlab, bitbucket)
54
54
  --audience Override audience (developer, end-user, executive)
55
+ --tone Override tone (professional, casual, terse, edgy, hype, snarky)
55
56
  --verbose Show detailed output
56
57
  --quiet Suppress all output except errors
57
58
 
@@ -63,6 +64,7 @@ var HELP = `
63
64
  $ cullit generate --source jira --from "project = PROJ" --provider anthropic
64
65
  $ cullit generate --source linear --from "team:ENG" --provider openai
65
66
  $ cullit generate --source gitlab --from v1.0.0 --to v1.1.0
67
+ $ cullit generate --from HEAD~5 --tone edgy --format html-edgy
66
68
  $ cullit init
67
69
  `;
68
70
  async function main() {
@@ -122,9 +124,19 @@ async function main() {
122
124
  process.exit(1);
123
125
  }
124
126
  async function runGenerate(from, to, opts) {
127
+ const configInput = opts.config || opts.c;
128
+ if (configInput) {
129
+ const resolvedConfig = resolve(configInput);
130
+ const projectRoot = resolve(process.cwd());
131
+ if (!resolvedConfig.startsWith(projectRoot)) {
132
+ console.error("\n\u2717 Config error: config file must be within the current project directory");
133
+ process.exitCode = 1;
134
+ return;
135
+ }
136
+ }
125
137
  let config;
126
138
  try {
127
- config = loadConfig(opts.config || opts.c || process.cwd());
139
+ config = loadConfig(configInput || process.cwd());
128
140
  } catch (err) {
129
141
  console.error(`
130
142
  \u2717 Config error: ${err.message}`);
@@ -135,6 +147,7 @@ async function runGenerate(from, to, opts) {
135
147
  const VALID_PROVIDERS = AI_PROVIDERS;
136
148
  const VALID_AUDIENCES = AUDIENCES;
137
149
  const VALID_SOURCES = SOURCE_TYPES;
150
+ const VALID_TONES = TONES;
138
151
  if (opts.provider) {
139
152
  if (!VALID_PROVIDERS.includes(opts.provider)) {
140
153
  console.error(`
@@ -155,6 +168,16 @@ async function runGenerate(from, to, opts) {
155
168
  }
156
169
  config.ai.audience = opts.audience;
157
170
  }
171
+ if (opts.tone) {
172
+ if (!VALID_TONES.includes(opts.tone)) {
173
+ console.error(`
174
+ \u2717 Invalid tone: ${opts.tone}`);
175
+ console.error(` Valid tones: ${VALID_TONES.join(", ")}`);
176
+ process.exitCode = 1;
177
+ return;
178
+ }
179
+ config.ai.tone = opts.tone;
180
+ }
158
181
  if (opts.model) config.ai.model = opts.model;
159
182
  if (opts.source) {
160
183
  if (!VALID_SOURCES.includes(opts.source)) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cullit",
3
- "version": "1.0.0",
3
+ "version": "1.5.0",
4
4
  "type": "module",
5
5
  "description": "Cull the noise from your releases. AI-powered release notes from the CLI.",
6
6
  "license": "MIT",
@@ -29,8 +29,8 @@
29
29
  "node": ">=18"
30
30
  },
31
31
  "dependencies": {
32
- "@cullit/config": "1.0.0",
33
- "@cullit/core": "1.0.0"
32
+ "@cullit/config": "1.5.0",
33
+ "@cullit/core": "1.5.0"
34
34
  },
35
35
  "scripts": {
36
36
  "build": "tsup src/index.ts --format esm --clean",