jiradc-cli 1.0.24 → 1.0.25
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/dist/index.js +6 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1315,24 +1315,26 @@ function registerCommentCommands(parent) {
|
|
|
1315
1315
|
|
|
1316
1316
|
// src/commands/issue/create.ts
|
|
1317
1317
|
function create3(parent) {
|
|
1318
|
-
const cmd = parent.command("create").description("Create a new issue").requiredOption("--project <key>", "Project key or ID").requiredOption("--type <name>", "Issue type name (e.g., Task, Bug, Story)").requiredOption("--summary <text>", "Issue summary/title").option("--assignee <
|
|
1318
|
+
const cmd = parent.command("create").description("Create a new issue").requiredOption("--project <key>", "Project key or ID").requiredOption("--type <name>", "Issue type name (e.g., Task, Bug, Story)").requiredOption("--summary <text>", "Issue summary/title").option("--assignee <user>", 'Assignee. Username, "me", or "none" to leave unassigned.').option("--reporter <user>", 'Reporter. Username or "me".').option("--priority <name>", "Priority name (e.g., High, Medium, Low)").option("--labels <labels>", "Comma-separated labels").option("--components <names>", "Comma-separated component names").option("--fix-versions <versions>", "Comma-separated fix version names").option("--due-date <date>", "Due date in YYYY-MM-DD format").option("--parent <key>", "Parent issue key (for subtasks)").option("--custom-fields <json>", `Additional custom fields as JSON (e.g., '{"customfield_10100": "EPIC-1"}')`);
|
|
1319
1319
|
textOrFileOption(cmd, "description", { description: "Issue description in wiki markup" });
|
|
1320
1320
|
examples(cmd, [
|
|
1321
1321
|
'--project PROJ --type Task --summary "Fix login bug"',
|
|
1322
|
-
'--project PROJ --type Story --summary "New feature" --assignee
|
|
1322
|
+
'--project PROJ --type Story --summary "New feature" --assignee me --priority High',
|
|
1323
1323
|
'--project PROJ --type Bug --summary "Urgent" --labels urgent,production --components Backend'
|
|
1324
1324
|
]);
|
|
1325
1325
|
cmd.action(
|
|
1326
1326
|
async (opts) => {
|
|
1327
1327
|
const description = resolveTextOrFile(opts, "description", { required: false });
|
|
1328
|
+
const assignee = opts.assignee !== void 0 ? await resolveUserToken(opts.assignee) : void 0;
|
|
1329
|
+
const reporter = opts.reporter !== void 0 ? await resolveUserToken(opts.reporter) : void 0;
|
|
1328
1330
|
const client = getClient();
|
|
1329
1331
|
const result = await client.issues.create({
|
|
1330
1332
|
projectKeyOrId: opts.project,
|
|
1331
1333
|
issueTypeName: opts.type,
|
|
1332
1334
|
summary: opts.summary,
|
|
1333
1335
|
description,
|
|
1334
|
-
assignee:
|
|
1335
|
-
reporter:
|
|
1336
|
+
assignee: assignee ?? void 0,
|
|
1337
|
+
reporter: reporter ?? void 0,
|
|
1336
1338
|
priority: opts.priority,
|
|
1337
1339
|
labels: opts.labels?.split(",").map((l) => l.trim()),
|
|
1338
1340
|
components: opts.components?.split(",").map((c) => c.trim()),
|