From 0559eaffa7ac17ad6a2ae85e3512f66be5cb5ec2 Mon Sep 17 00:00:00 2001 From: Anas Fikhi Date: Fri, 1 Dec 2023 06:02:47 +0100 Subject: [PATCH] [ Edit ] --- .../commands/start_command/start_command.dart | 28 +++++++++---------- lib/src/etc/models/user_info.dart | 2 +- lib/src/etc/networking/client.dart | 4 ++- lib/src/etc/utils.dart | 1 - pubspec.yaml | 2 +- 5 files changed, 19 insertions(+), 18 deletions(-) diff --git a/lib/src/commands/start_command/start_command.dart b/lib/src/commands/start_command/start_command.dart index 754dedf..9b14945 100644 --- a/lib/src/commands/start_command/start_command.dart +++ b/lib/src/commands/start_command/start_command.dart @@ -190,24 +190,24 @@ class StartCommand extends Command { } } - void _writeResultToFiles({ - required Map res, - required Directory outputDir, - }) { - final progress = logger.customProgress('Writing results to files..'); + // void _writeResultToFiles({ + // required Map res, + // required Directory outputDir, + // }) { + // final progress = logger.customProgress('Writing results to files..'); - res.forEach((key, value) { - final file = File('${outputDir.path}/$key.json'); + // res.forEach((key, value) { + // final file = File('${outputDir.path}/$key.json'); - if (!file.existsSync()) { - file.createSync(recursive: true); - } + // if (!file.existsSync()) { + // file.createSync(recursive: true); + // } - progress.update('Writing $key.json'); + // progress.update('Writing $key.json'); - file.writeAsStringSync(value.toPrettyJson()); - }); - } + // file.writeAsStringSync(value.toPrettyJson()); + // }); + // } Future _writeNewLocalizationFiles({ required List outputList, diff --git a/lib/src/etc/models/user_info.dart b/lib/src/etc/models/user_info.dart index ea86022..f4b0df9 100644 --- a/lib/src/etc/models/user_info.dart +++ b/lib/src/etc/models/user_info.dart @@ -1,6 +1,6 @@ import 'package:equatable/equatable.dart'; import 'package:langsync/src/etc/extensions.dart'; -import 'package:langsync/src/etc/models/Localization_doc.dart'; +import 'package:langsync/src/etc/models/localization_doc.dart'; class UserInfo extends Equatable { const UserInfo({ diff --git a/lib/src/etc/networking/client.dart b/lib/src/etc/networking/client.dart index 4aedb6d..cf51d8c 100644 --- a/lib/src/etc/networking/client.dart +++ b/lib/src/etc/networking/client.dart @@ -20,7 +20,9 @@ class NetClient extends NetClientBoilerPlate { required Iterable langs, required String apiKey, required String operationId, - required int? languageLocalizationMaxDelay, required String? instruction, bool includeOutput = false, + required int? languageLocalizationMaxDelay, + required String? instruction, + bool includeOutput = false, }) { return sseStreamReq>( '/process-translation', diff --git a/lib/src/etc/utils.dart b/lib/src/etc/utils.dart index 65d8eb3..627267e 100644 --- a/lib/src/etc/utils.dart +++ b/lib/src/etc/utils.dart @@ -1,7 +1,6 @@ import 'dart:io'; import 'dart:math'; - final utils = Utils(); class Utils { diff --git a/pubspec.yaml b/pubspec.yaml index eeab3eb..2d62294 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,5 +1,5 @@ name: langsync -description: A Very Good Project created by Very Good CLI. +description: an AI powered localization tool for any platform and language. version: 0.9.5 homepage: https://langsync.app repository: https://github.com/LangSync/cli