Fix : mobile issues and git diff in the git panel

This commit is contained in:
simos
2025-09-15 20:57:49 +00:00
parent fb1117a999
commit 79981693f3
6 changed files with 84 additions and 48 deletions

View File

@@ -899,22 +899,16 @@ async function addProjectManually(projectPath, displayName = null) {
// Generate project name (encode path for use as directory name)
const projectName = absolutePath.replace(/\//g, '-');
// Check if project already exists in config or as a folder
// Check if project already exists in config
const config = await loadProjectConfig();
const projectDir = path.join(process.env.HOME, '.claude', 'projects', projectName);
try {
await fs.access(projectDir);
throw new Error(`Project already exists for path: ${absolutePath}`);
} catch (error) {
if (error.code !== 'ENOENT') {
throw error;
}
}
if (config[projectName]) {
throw new Error(`Project already configured for path: ${absolutePath}`);
}
// Allow adding projects even if the directory exists - this enables tracking
// existing Claude Code or Cursor projects in the UI
// Add to config as manually added project
config[projectName] = {