@vibetasks/cli 0.6.5 → 0.6.6

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.
@@ -672,6 +672,12 @@ var addCommand = new Command2("add").description("Add a new task").argument("<ti
672
672
  title: subtaskTitle,
673
673
  done: false
674
674
  })) || [];
675
+ let sessionId;
676
+ if (createdBy === "ai") {
677
+ const sessionManager2 = getSessionManager();
678
+ const session = await sessionManager2.getOrCreateSession(projectTag);
679
+ sessionId = session.id;
680
+ }
675
681
  const task = await taskOps.createTask({
676
682
  title,
677
683
  notes: options.notes,
@@ -685,7 +691,9 @@ var addCommand = new Command2("add").description("Add a new task").argument("<ti
685
691
  status: createdBy === "ai" ? "vibing" : "todo",
686
692
  // AI tasks start vibing
687
693
  energy_required: options.energy,
688
- subtasks_json: subtasksJson
694
+ subtasks_json: subtasksJson,
695
+ session_id: sessionId
696
+ // Link to AI session for ownership tracking
689
697
  });
690
698
  if (options.tags && options.tags.length > 0) {
691
699
  const tagIds = [];
@@ -840,7 +848,7 @@ var ShortIdManager = class {
840
848
  };
841
849
 
842
850
  // src/commands/list.ts
843
- var listCommand = new Command3("list").description("List tasks").argument("[filter]", "Filter: all, today, upcoming, completed", "all").option("-l, --limit <number>", "Maximum number of tasks to show", "50").option("--project <name>", "Filter by project tag").option("--created-by <source>", "Filter by creator: ai or human").option("--status <status>", "Filter by status: todo, vibing, done").option("--short-ids", "Show short numeric IDs (1-99) for easy reference").action(async (filter, options) => {
851
+ var listCommand = new Command3("list").description("List tasks").argument("[filter]", "Filter: all, today, upcoming, completed", "all").option("-l, --limit <number>", "Maximum number of tasks to show", "50").option("--project <name>", "Filter by project tag").option("--created-by <source>", "Filter by creator: ai or human").option("--status <status>", "Filter by status: todo, vibing, done").option("--session [id]", "Filter by session (current session if no ID given)").option("--my-session", "Only show tasks from current AI session").option("--short-ids", "Show short numeric IDs (1-99) for easy reference").action(async (filter, options) => {
844
852
  try {
845
853
  const validFilters = ["all", "today", "upcoming", "completed"];
846
854
  if (!validFilters.includes(filter)) {
@@ -870,6 +878,32 @@ var listCommand = new Command3("list").description("List tasks").argument("[filt
870
878
  }
871
879
  tasks = tasks.filter((t) => t.status === options.status);
872
880
  }
881
+ if (options.mySession || options.session !== void 0) {
882
+ const sessionManager2 = getSessionManager();
883
+ let targetSessionId;
884
+ if (options.session && typeof options.session === "string") {
885
+ const session = await sessionManager2.getSession(options.session);
886
+ if (session) {
887
+ targetSessionId = session.id;
888
+ } else {
889
+ console.error(chalk4.red(`Session "${options.session}" not found`));
890
+ process.exit(1);
891
+ }
892
+ } else {
893
+ const currentSession = await sessionManager2.getCurrentSession();
894
+ if (currentSession) {
895
+ targetSessionId = currentSession.id;
896
+ } else {
897
+ console.log(chalk4.yellow("No active session. Start one with: vibetasks session start"));
898
+ process.exit(0);
899
+ }
900
+ }
901
+ if (targetSessionId) {
902
+ tasks = tasks.filter((t) => t.session_id === targetSessionId);
903
+ console.log(chalk4.gray(`Filtering by session: ${chalk4.cyan(targetSessionId)}
904
+ `));
905
+ }
906
+ }
873
907
  if (tasks.length === 0) {
874
908
  const filterMessages = {
875
909
  all: "No active tasks found",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@vibetasks/cli",
3
- "version": "0.6.5",
3
+ "version": "0.6.6",
4
4
  "description": "VibeTasks CLI - Lightning-fast task management from your terminal. Works with Claude Code, Cursor, and all AI coding tools.",
5
5
  "author": "Vyas",
6
6
  "license": "MIT",
@@ -45,8 +45,8 @@
45
45
  "typecheck": "tsc --noEmit"
46
46
  },
47
47
  "dependencies": {
48
- "@vibetasks/core": "^0.5.6",
49
- "@vibetasks/shared": "^1.4.5",
48
+ "@vibetasks/core": "^0.5.6",
49
+ "@vibetasks/shared": "^1.4.5",
50
50
  "commander": "^11.1.0",
51
51
  "chalk": "^5.3.0",
52
52
  "ora": "^8.0.1",