getRootPath method

Future<String?> getRootPath()

Get workspace root path

Implementation

Future<String?> getRootPath() async {
  final folders = await getWorkspaceFolders();
  return folders.isNotEmpty ? folders.first.uri.fsPath : null;
}