diff --git a/bin/vide.dart b/bin/vide.dart index 4c3cbd65..7a79d2f7 100644 --- a/bin/vide.dart +++ b/bin/vide.dart @@ -22,5 +22,5 @@ void main(List args) async { workingDirProvider.overrideWithValue(Directory.current.path), ]; - app.main(args, overrides: overrides); + await app.main(args, overrides: overrides); } diff --git a/lib/main.dart b/lib/main.dart index ab602408..1d946910 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -28,7 +28,7 @@ final _canUseToolCallbackFactoryOverride = canUseToolCallbackFactoryProvider.ove }; }); -void main(List args, {List overrides = const []}) async { +Future main(List args, {List overrides = const []}) async { // Initialize Sentry and set up nocterm error handler await SentryService.init(); diff --git a/packages/vide_core/lib/services/vide_config_manager.dart b/packages/vide_core/lib/services/vide_config_manager.dart index 4017488c..3126b3a4 100644 --- a/packages/vide_core/lib/services/vide_config_manager.dart +++ b/packages/vide_core/lib/services/vide_config_manager.dart @@ -69,15 +69,17 @@ class VideConfigManager { /// /// Replaces forward slashes (/) with hyphens (-) /// Example: /Users/bob/project -> -Users-bob-project + /// On Windows: D:\project -> D-project (colon removed as it's invalid in filenames) String _encodeProjectPath(String absolutePath) { // Normalize the path first to handle trailing slashes, etc. final normalized = path.normalize(absolutePath); // Replace path separators with hyphens - // On Windows, also handle backslashes + // On Windows, also handle backslashes and colons (invalid in filenames) String encoded = normalized.replaceAll('/', '-'); if (Platform.isWindows) { encoded = encoded.replaceAll('\\', '-'); + encoded = encoded.replaceAll(':', ''); // Remove colons (e.g., D: -> D) } return encoded;