diff --git a/bin/nostr_console.dart b/bin/nostr_console.dart index 4c89e7e..7967b7f 100644 --- a/bin/nostr_console.dart +++ b/bin/nostr_console.dart @@ -32,6 +32,7 @@ const String locationArg = "location"; const String lnQrFlag = "lnqr"; Future main(List arguments) async { + final parser = ArgParser()..addOption(requestArg) ..addOption(pubkeyArg, abbr:"p")..addOption(prikeyArg, abbr:"k") ..addOption(lastdaysArg, abbr:"d") ..addOption(relayArg, abbr:"r") diff --git a/lib/console_ui.dart b/lib/console_ui.dart index 868412f..ae4f0f6 100644 --- a/lib/console_ui.dart +++ b/lib/console_ui.dart @@ -30,6 +30,7 @@ Future processAnyIncomingEvents(Store node, [bool printNotifications = tru List numPrinted1 = [0,0,0]; if( printNotifications) { // print all the new trees, the ones that we want to print + print(""); numPrinted1 = node.printTreeNotifications(newEventIds); // need to clear because only top 20 events in each thread are printed or cleared with above @@ -479,6 +480,7 @@ int showMenu(List menuOptions, String menuName, [String menuInfo = ""]) stdout.write("Type option number: "); String? userOptionInput = stdin.readLineSync(); String userOption = userOptionInput??""; + userOption = userOption.trim(); if( userOption == 'x') { userOption = menuOptions.length.toString(); @@ -1596,6 +1598,20 @@ void directRoomNotifications(Store node, [int x = 0, int y = 0]) { Future mainMenuUi(Store node) async { + var n; + + /* TODO + ProcessSignal.sigint.watch().listen((signal) { + print(" caught ${n} of 3"); + clearScreen(); + print("\nExiting. Writing file $gEventsFilename. "); + if( gEventsFilename != "") { + node.writeEventsToFile(gEventsFilename); + } + exit(0); + }); */ + + clearScreen(); //Show only notifications diff --git a/lib/settings.dart b/lib/settings.dart index e73f9f4..3d8c726 100644 --- a/lib/settings.dart +++ b/lib/settings.dart @@ -3,7 +3,7 @@ import 'package:logging/logging.dart'; // name of executable const String exename = "nostr_console"; -const String version = "0.3.3-beta-a"; +const String version = "0.3.4-beta"; int gDebug = 0; int gSpecificDebug = 0; diff --git a/lib/tree_ds.dart b/lib/tree_ds.dart index 5a86220..d081a2f 100644 --- a/lib/tree_ds.dart +++ b/lib/tree_ds.dart @@ -1630,7 +1630,7 @@ class Store { ret[0] += temp[0]; ret[1] += temp[1]; ret[2] += temp[2]; - print("\n"); + //print("\n"); } }); diff --git a/pubspec.yaml b/pubspec.yaml index dbed422..88276bb 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -1,13 +1,14 @@ name: nostr_console description: A multi-platform nostr client built for terminal/console -version: 0.3.3-beta-a +version: 0.3.4-beta homepage: https://github.com/vishalxl/nostr_console # 0.3.4 -# improved logic that only new events from follows are shown +# improved logic that only new events from follows are shown; this reduces the flood of notifications seen # longer-named follows were not getting tick mark at end. fixed it, now they get tick marks in posts, channels and in one liners for channels +# fix lud06/16 qr code printing in profiles # 0.3.3 # Linux arm64 build added; docker images pushed to github store; and improving of build process by @AaronDewes