feat: découverte automatique des dépôts git (scan + montrer/cacher)

Scan borné du système de fichiers (racines configurables, défaut home ; profondeur/nombre/timeout bornés ; symlinks non suivis ; exclusions node_modules/dotdirs) qui auto-enregistre les nouveaux dépôts. Insertion atomique ON CONFLICT DO NOTHING (idempotence + anti-résurrection d'un dépôt masqué + anti-course). Scan au démarrage + bouton manuel + re-scan périodique (RepoDiscoveryService, démarré dans runDaemon). Colonne repos.hidden : masquer = conservé en DB mais exclu du dashboard et jamais ré-ajouté ; supprimer = re-découvrable. UI : bouton œil par dépôt + bascule afficher-les-masqués sur le dashboard, section Découverte dans les Réglages (racines + intervalle, allow-list stricte). Robustesse : listAllWorktrees tolère l'échec git par dépôt ; flag --no-discover (escape hatch + hermétisme des acceptations).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
Johan LEROY
2026-06-18 14:45:12 +02:00
parent 940ccffeab
commit fa9952bc5c
28 changed files with 824 additions and 34 deletions

View File

@@ -8,12 +8,16 @@ import { api } from '../lib/api';
export const useSettingsStore = defineStore('settings', () => {
const server = ref<ServerInfo | null>(null);
const giteaUrl = ref<string | null>(null);
const scanRoots = ref<string[]>([]);
const scanIntervalMin = ref(0);
const loaded = ref(false);
const saving = ref(false);
function apply(res: SettingsResponse): void {
server.value = res.server;
giteaUrl.value = res.settings.giteaUrl;
scanRoots.value = res.settings.scanRoots;
scanIntervalMin.value = res.settings.scanIntervalMin;
loaded.value = true;
}
@@ -30,5 +34,5 @@ export const useSettingsStore = defineStore('settings', () => {
}
}
return { server, giteaUrl, loaded, saving, fetch, save };
return { server, giteaUrl, scanRoots, scanIntervalMin, loaded, saving, fetch, save };
});