Commit graph

191 commits

Author SHA1 Message Date
Leon Mika 213a4fc9cc Renamed the pasteboard commands and added additinal tests
All checks were successful
ci / build (push) Successful in 3m25s
2025-05-28 21:45:59 +10:00
Leon Mika 204c79ca2d Started working on functions for creating attribute values
All checks were successful
ci / build (push) Successful in 3m20s
Also finished mapping attribute values to/from UCL
2025-05-27 21:45:09 +10:00
Leon Mika 32ae488066 Moved package to lmika.dev/cmd/dynamo-browse
All checks were successful
ci / build (push) Successful in 3m17s
2025-05-26 22:04:23 +10:00
Leon Mika 8b5b5798da Merge branch 'feature/ucl'
All checks were successful
ci / build (push) Successful in 3m18s
2025-05-26 21:54:55 +10:00
Leon Mika 291d1439f4 Removed the script controller
Some checks failed
ci / build (pull_request) Has been cancelled
2025-05-26 21:45:36 +10:00
Leon Mika 76dce52a86 Added opt:set 2025-05-26 21:20:46 +10:00
Leon Mika cae7509a76 Almost feature complete
- Added reading of UCL scripts
- Added pasteboard commands
- Added ui:command which will define a proc at the top-level
2025-05-25 13:31:00 +10:00
Leon Mika 7ae99b009b ucl: added rs:set 2025-05-23 22:04:41 +10:00
Leon Mika 5088009672 ucl: added more resultset functions 2025-05-19 22:14:22 +10:00
Leon Mika 40f8dd76e2 ucl: Have started adding some of the psudo variables 2025-05-18 13:42:44 +10:00
Leon Mika 18ffe85a56 First attempt at a resultset pseudovar
The resultset needs a table set, so rs:new will also assume the current table.
2025-05-17 22:16:49 +10:00
Leon Mika 40136e3936 Made test DynamoDB endpoint configurable
All checks were successful
ci / build (push) Successful in 5m11s
2025-05-17 11:18:40 +10:00
Leon Mika 6bf721873b Added rs:new and rs:query 2025-05-17 11:11:04 +10:00
Leon Mika cb908ec4eb Added back the core interactive commands 2025-05-16 18:01:28 +10:00
Leon Mika 17381f3d0b Started re-engineering the UCL command instance 2025-05-15 22:16:02 +10:00
Leon Mika aae3c419db Fixed dependencies and CI/CD pipelines
Some checks failed
ci / build (push) Has been cancelled
2025-04-29 20:04:44 +10:00
Leon Mika 94b58e2168 Updated UCL and added an interactive mode 2024-05-04 11:40:24 +10:00
Leon Mika 29d425c77e Fixed deadlock with message listener 2024-05-01 21:45:47 +10:00
Leon Mika b2ddc62555 ucl: integrated ucl with the command evaluator 2024-05-01 21:30:47 +10:00
Leon Mika e37b8099a3 Fixed a glaring error where the user cannot close the column selector
Some checks failed
ci / build (push) Has been cancelled
Cause of this was that the close event type was also being used by the related overlay, and the event was being caught by that even though the overlay was hidden.

Also started working on changing the sort order within the column selector by pressing S.
2024-04-02 23:00:19 +11:00
Leon Mika f5bf31a903 Fixed release CI/CD and added 'C' as copy to table binding 2024-03-03 09:48:03 +11:00
Leon Mika 5d95d44a97
Added the rel-picker which can quickly goto related tables
* New rel-picker that can be opened using Shift+O and allows for quickly going to related tables.
2024-03-03 09:20:28 +11:00
Leon Mika 12909c89ee Removed internal os module
Module "os" is no longer needed since Risor comes with an "os" and "exec" module out of the box now.
2024-03-03 08:54:57 +11:00
Leon Mika ceb064a346 Upgraded to Risor 1.4.0 2024-03-03 08:34:41 +11:00
Leon Mika 7ca0cf6982
Converted scripting language Tamarin to Risor (#55)
- Converted Tamarin script language to Risor
- Added a "find" and "merge" method to the result set script type.
- Added the ability to copy the table of results to the pasteboard by pressing C
- Added the -q flag, which will run a query and display the results as a CSV file on the command line
- Upgraded Go to 1.21 in Github actions
- Fix issue with missing limits
- Added the '-where' switch to the mark
- Added the 'marked' function to the query expression.
- Added a sampled time and count on the right-side of the mode line
- Added the 'M' key binding to toggle the marked items
- Started working on tab completion for 'sa' and 'da' commands
- Added count and sample time to the right-side of the mode line
- Added Ctrl+V to the prompt to paste the text of the pasteboard with all whitespace characters trimmed
- Fixed failing unit tests
2023-10-06 15:27:06 +11:00
Leon Mika ed53173a1d
Added the "export -all" switch (#54)
Extended the "export" command with an "-all" flag. When included, all rows of the table matching the query will be exported to CSV.
2023-07-31 20:59:05 +10:00
Leon Mika 20a9a8c758 fix: Added a small timeout to the runNow() script scheduler
This is to avoid a small race conditions in the tests, where a script has signalled that it's finished loading but the schedular has not started waiting for the next task.
2023-07-03 11:24:16 +10:00
Leon Mika f65c5778a9
issue-50: fixed package name (#52)
Changed package name from github.com/lmika/audax to github.com/lmika/dynamo-browse
2023-04-17 08:31:03 +10:00
Leon Mika 4b4d515ade
Added a few changes to query expressions (#51)
- Added the between operator to query expressions.
- Added the using query expression suffix to specify which index to query (or force a scan). This is required if query planning has found multiple indices that can potentially be used.
- Rewrote the types of the query expressions to allow for functions to be defined once, and be useful in queries that result in DynamoDB queries, and evaluation.
- Added some test functions around time and summing numbers.
- Fixed a bug in the del-attr which was not honouring marked rows in a similar way to set-attr: it was only deleting attributes from the first row.
- Added the -to type flag to set-attr which will set the attribute to the value of a query expression.
2023-04-14 15:35:43 +10:00
Leon Mika 835ddd5630 Updated README.md 2023-03-08 21:48:44 +11:00
Leon Mika 3f1c6b6c3d Fixed homepage of dynamo-browse in MacOS goreleaser 2023-03-08 21:44:46 +11:00
Leon Mika cbbdea75a0 Fixes made as part of updating the user manual 2023-03-07 22:28:10 +11:00
Leon Mika 72b7a40e23 Updated version number 2023-02-23 21:51:49 +11:00
Leon Mika 937af987e6 Removed the other tools and fixed the README.md file 2023-02-23 21:45:50 +11:00
Leon Mika ab309084c5 Refreshing will update the columns if they haven't been rearranged 2023-02-23 21:31:01 +11:00
Leon Mika 3f1aec2c87
Made table information available to scripts (#49)
- Added a property with table information to session and result set Script types
- Added the ability to add new key bindings to the script
- Rebuilt the foreground job dispatcher to reduce the occurrence of the progress indicator showing up when no job was running.
- Fixed rebinding of keys. Rebinding a key will no longer clear other keys for the old or new bindings.
2023-02-22 21:53:05 +11:00
Leon Mika 733e59ec95
Issue 47: Query expression planner now recognises GSIs (#48)
The query expression planner now recognises GSIs, and will use them if the expression can be executed as a query over an index.
2023-02-17 09:17:22 +11:00
Leon Mika 7caf905c82
Added sub references to the query expression (#46)
These are the `thing[subref]` construct. Subrefs can either be a string or an integer.

At the moment, multiple sub references, such as `thing[1][2][3]` doesn't work. This is because the SDK does not properly handle this when creating the actual expression.
2023-02-16 21:57:40 +11:00
Leon Mika 348251c1cf Finished the mapping between dynamo attribute values and tamarin values 2023-01-29 09:12:39 +11:00
Leon Mika 3bf5b6ec93 Merge remote-tracking branch 'refs/remotes/origin/main' 2023-01-28 10:00:48 +11:00
Leon Mika 54a120342e
Added command history (#45)
* Added command line history to the command, query and filter prompts.
* Added query planning debugging to the log.
* Fixed bug in query expression which was not treating true and false as boolean literals.
* Fixed a bug in the query planning logic which was incorrectly determine that an expression of the form sort_key ^= "string", with no partition key, could be executed as a query instead of a scan.
2023-01-26 21:46:31 +11:00
Leon Mika aaf3c17934 Fixed query expression so that 'true' and 'false' are now boolean literals
Also describe queries in the log file
2023-01-26 10:34:43 +11:00
Leon Mika 700a1a2253 Fixed bad value errors when trying to set default-limit without specifying a value
Now, when calling 'set' with a name but no value, with a few exceptions, the current setting value will be displayed.
2023-01-23 21:45:12 +11:00
Leon Mika ad1a77a257
Added paging and the ability to specify the table in query script method (#44)
* paging: added controller for paging through results
* paging: added command and key binding for going to the next page
* paging: added the ability to specify the table in the query script method
* paging: have got exclusive start key written to backstack
2023-01-23 21:23:46 +11:00
Leon Mika 9e658b8619
scripting: allowed access to environment variables (#41) 2023-01-11 21:44:22 +11:00
Leon Mika c89b09447c
Initial version of scripting (#40)
* scripting: added service and controller for scripting

* scripting: have got prompts working

Scripts are now running in a separate go-routine.  When a prompt is encountered, the
script is paused and the user is prompted for input.  This means that the script no
longer needs to worry about synchronisation issues.

* scripting: started working on the session methods

* scripting: added methods to get items and attributes

* scripting: have got loading of scripts working

These act more like plugins and allow defining new commands.

* scripting: have got script scheduling working

Scripts are now executed on a dedicated goroutine and only one script can run at any one time.

* scripting: added session.set_result_set(rs)

* scripting: upgraded tamarin to 0.14

* scripting: started working on set_value

* tamarin: replaced ad-hoc path with query expressions

* scripting: changed value() and set_value() to attr() and set_attr()

Also added 'delete_attr()'

* scripting: added os.exec()

This method is controlled by permissions which govern whether shellouts are allowed
Also fixed a resizing bug with the status window which was not properly handling status messages with newlines

* scripting: added the session.current_item() method

* scripting: added placeholders to query expressions

* scripting: added support for setting and deleteing items with placeholders

Also refactored the dot AST type so that it support placeholders.  Placeholders are not yet supported
for subrefs yet, they need to be identifiers.

* scripting: made setting the result-set push the current result-set to the backstack

* scripting: started working on byte encoding of attribute values

* scripting: finished attrcodec

* scripting: integrated codec into expression

* scripting: added equals and hashcode to queryexpr

This finally finishes the work required to store queries in the backstack

* scripting: fixed some bugs with the back-stack

* scripting: upgraded Tamarin

* scripting: removed some commented out code
2023-01-10 22:27:13 +11:00
Leon Mika cd9700569c Another fix to the release 2022-11-18 22:46:50 +11:00
Leon Mika e388bec89f Fixed some bugs with the releases 2022-11-18 22:29:59 +11:00
Leon Mika 55b8103416
Split the releases into a MacOS one and Linux/Windows one
This is to add support for building the MacOS binary using CGO.
2022-11-18 22:14:33 +11:00
Leon Mika 0c541da1c6 Changed worker for CI/CD back to ubuntu 2022-11-18 07:55:40 +11:00