mirror of
https://github.com/cake-tech/cake_wallet.git
synced 2024-12-22 11:39:22 +00:00
311fff2c44
* update target sdk for android * make welcome page scrollable fix moonpay url params * fix null exception when restoring from backup * fix ui issues * hopefully fix the timeout exception error report [skip ci] * validate electrum addresses * disable silent payments for hardware wallets * fixes and enhancements
34 lines
No EOL
930 B
Dart
34 lines
No EOL
930 B
Dart
import 'utils/translation/arb_file_utils.dart';
|
|
import 'utils/translation/translation_constants.dart';
|
|
import 'utils/translation/translation_utils.dart';
|
|
|
|
/// flutter packages pub run tool/append_translation.dart "hello_world" "Hello World!"
|
|
|
|
void main(List<String> args) async {
|
|
if (args.length != 2) {
|
|
throw Exception(
|
|
'Insufficient arguments!\n\nTry to run `./append_translation.dart greetings "Hello World!"`');
|
|
}
|
|
|
|
final name = args.first;
|
|
final text = args.last;
|
|
|
|
print('Appending "$name": "$text"');
|
|
|
|
// add translation to all languages:
|
|
for (var lang in langs) {
|
|
final fileName = getArbFileName(lang);
|
|
final translation = await getTranslation(text, lang);
|
|
|
|
appendStringToArbFile(fileName, name, translation);
|
|
}
|
|
|
|
print('Alphabetizing all files...');
|
|
|
|
for (var lang in langs) {
|
|
final fileName = getArbFileName(lang);
|
|
alphabetizeArbFile(fileName);
|
|
}
|
|
|
|
print('Done!');
|
|
} |