Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,12 @@

# Changelog

## [1.0.22] - 2025-10-02

### Fixed

- Decode URL-encoded `file://` roots on Windows when resolving `DATA_DIR`, preventing paths like `e%3A` from being used and ensuring files are written to the correct drive.

## [1.0.21] - 2025-01-13

### Added
Expand Down Expand Up @@ -32,6 +38,7 @@
- **Node.js HTTP Server**: RESTful API endpoints for task and profile management
- **HTML5 Drag & Drop**: Native browser API for intuitive tab reordering
- **CSS Grid & Flexbox**: Responsive layout system with mobile-first approach

### Changed

- Updated documentation to reflect new configuration options (99baa0f, 8771a5b)
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "mcp-shrimp-task-manager",
"version": "1.0.21",
"version": "1.0.22",
"description": "Shrimp Task Manager is a task tool built for AI Agents, emphasizing chain-of-thought, reflection, and style consistency. It converts natural language into structured dev tasks with dependency tracking and iterative refinement, enabling agent-like developer behavior in reasoning AI systems",
"main": "dist/index.js",
"type": "module",
Expand Down Expand Up @@ -48,4 +48,4 @@
"typescript": "^5.2.2",
"vitest": "^1.0.0"
}
}
}
21 changes: 16 additions & 5 deletions src/utils/paths.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,14 +52,25 @@ export async function getDataDir(): Promise<string> {
root.uri.startsWith("file://")
);
if (firstFileRoot) {
// 從 file:// URI 中提取實際路徑
// Extract actual path from file:// URI
// 從 file:// URI 中提取實際路徑並進行 URL 解碼
// Extract actual path from file:// URI and URL decode
// Windows: file:///C:/path -> C:/path
// Unix: file:///path -> /path
if (process.platform === 'win32') {
rootPath = firstFileRoot.uri.replace("file:///", "").replace(/\//g, "\\");
let rawPath: string;
if (process.platform === "win32") {
rawPath = firstFileRoot.uri
.replace("file:///", "")
.replace(/\//g, "\\");
} else {
rootPath = firstFileRoot.uri.replace("file://", "");
rawPath = firstFileRoot.uri.replace("file://", "");
}

try {
// URL decode the path to handle %3A -> : conversion and other encoded characters
rootPath = decodeURIComponent(rawPath);
} catch (error) {
// If URL decoding fails, use the raw path as fallback
rootPath = rawPath;
}
}
}
Expand Down