File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
55The format is based on [ Keep a Changelog] ( https://keepachangelog.com/en/1.0.0/ ) ,
66and this project adheres to [ Semantic Versioning] ( https://semver.org/spec/v2.0.0.html ) .
77
8+ ## [ 1.2.0] - 2025-02-14
9+
10+ - ✨ Connection string options start at 1 instead of 0 making it more natural for keyboard layout
11+ - ✨ Connection string selection only needs a key press when there are less than 10 items
12+
813## [ 1.1.0] - 2025-02-11
914
1015- ✨ Added ability to select auto-detected envvar connection string
Original file line number Diff line number Diff line change @@ -93,7 +93,7 @@ list of transport configuration to choose from when launched.
9393 or Learning transport.
9494
9595 Azure Service Bus:
96-
96+
9797 Are expected to start with "Endpoint="
9898
9999 RabbitMQ:
@@ -214,14 +214,16 @@ static bool SetupTransport()
214214 for ( int i = 0 ; i < transports . Count ; i ++ )
215215 {
216216 var cyan = Ansi . GetAnsiColor ( ConsoleColor . DarkCyan ) ;
217- Console . WriteLine ( $ " [{ cyan } { i } { Ansi . Reset } ] { transports [ i ] . key } : { transports [ i ] . type } ") ;
217+ Console . WriteLine ( $ " [{ cyan } { i + 11 } { Ansi . Reset } ] { transports [ i ] . key } : { transports [ i ] . type } ") ;
218218 }
219219
220220 Console . Write ( "\n Option: " ) ;
221221
222- var x = int . Parse ( Console . ReadLine ( ) ) ;
222+ var indexStartAt1 = transports . Count < 10
223+ ? int . Parse ( Console . ReadKey ( ) . KeyChar . ToString ( ) )
224+ : int . Parse ( Console . ReadLine ( ) ) ;
223225
224- ConnectionString = transports [ x ] . v ;
226+ ConnectionString = transports [ -- indexStartAt1 ] . v ;
225227 ConnectionString = Environment . ExpandEnvironmentVariables ( ConnectionString ) ;
226228 }
227229
You can’t perform that action at this time.
0 commit comments