Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

user-catalogue scheduled refreshes #399

Merged
merged 8 commits into from
May 17, 2023
Merged

user-catalogue scheduled refreshes #399

merged 8 commits into from
May 17, 2023

Conversation

torkus
Copy link
Contributor

@torkus torkus commented Apr 27, 2023

if a user-catalogue is more than 28 days old, it will trigger an automatic refresh and all addons that have been imported, or starred, will have it's user-catalogue entry matched against the full catalogue or imported again from online.

  • add opt-in preference
  • preference is toggle-able from gui
  • review
  • update CHANGELOG

@torkus torkus marked this pull request as ready for review May 13, 2023 01:28
src/strongbox/cli.clj Outdated Show resolved Hide resolved
src/strongbox/config.clj Outdated Show resolved Hide resolved
src/strongbox/core.clj Outdated Show resolved Hide resolved
src/strongbox/core.clj Outdated Show resolved Hide resolved
src/strongbox/core.clj Outdated Show resolved Hide resolved
src/strongbox/core.clj Outdated Show resolved Hide resolved
src/strongbox/core.clj Outdated Show resolved Hide resolved
src/strongbox/core.clj Outdated Show resolved Hide resolved
src/strongbox/utils.clj Outdated Show resolved Hide resolved
test/strongbox/cli_test.clj Outdated Show resolved Hide resolved
@torkus torkus merged commit c25c831 into develop May 17, 2023
@torkus torkus deleted the scheduled-refreshes branch May 17, 2023 11:50
torkus added a commit that referenced this pull request Jun 11, 2023
* updated TODO, changelog, project.clj

* updated TODO

* updated TODO

* build-linux-image, changed jlink compress=2 to compress=1
this leads to shaving ~7MB off of final AppImage.
'2' means 'zip', which (I think) interferes with AppImage compression.

* project.clj, moves dev/test dependencies into :repl/:dev profiles.
moves 'test' from 'main' into repl/strongbox/user.clj.
core.clj, replaces bz2 compressed catalogue with a simple string. two reasons:
1. it wasn't working at compile time like I thought.
2. regular strings are more compressible ultimately when building an AppImage.

* user.clj, adds 'restart' back in

* project.clj, bumps most dependencies, moves dev.plugins under plugins

* jfx.clj, pushed some init calls into async startup.
moved 'set-icon' after core/refresh as it's taking a long time to do it's thing.

* core, download-strongbox-release now acquires a lock.
core, latest-strongbox-version? no longer attempts to download latest version.
core, latest-strongbox-release no longer recurses on failure, preferring one download attempt per session.

* review feedback

* updated CHANGELOG

* updated CHANGELOG

* addon folder size  (#395)

* addons, adds `:dirsize` to addon spec and new column to gui
* utils, adds a bytes formatter copied from clj-commons/humanize.
  LICENCE updated
* specs, :dirsize added to 'fat' profiles
* jfx, fixed case where sometimes the given bytes to formatter is nil
* addon, sums the total :dirsize for all grouped addons
* addon, if total :dirsize is 0, don't bother including field.
  nicer while testing.
* :dirsize during testing is now zero
* updates tests with new :dirsizes
* utils, with-lock, pulls wait time out of macro
  shortened wait duration during testing as it was often failing during CI
* review feedback
* updated CHANGELOG

* user-catalogue, adds star button to installed addons tab (#396)

* jfx, adds star column to installed-addon-pane.
* cli, moved column-map back into jfx. 
  it was unnecessary and ultimately more difficult to maintain.
* jfx, starring and unstarring from installed addons pane now works.
* jfx, star column styling fixed.
* jfx, added star column sorting.
* cli, core, adds logic to find an :addon/summary from an :addon/installed so it can be added to the user-catalogue.
* jfx, ignored addons cannot be starred.
* cli, error message after failing to add addon to user-catalogue is logged against addon.
* jfx, addons without a catalogue match cannot be starred.
* jfx, tweaks menu labels for installed addon columns.
* jfx, fat profile now includes star column.
* jfx, fat profile now uses the separate installed and available versions in favour of the combined installed+available version column.

* user-catalogue, improvements now that github has it's own catalogue (#397)

* cli, refresh-user-catalogue will only attempt an exhanustive lookup if addon not found in full catalogue.
  full catalogue includes the github catalogue these days.
* updated CHANGELOG

* search, add 'clear' button (#398)

* jfx, search pane, adds 'clear' button that resets search state.
* jfx, 'clear' button disabled when search not customised.
* cli, tweaks some log messages to remove redundant information
* jfx, search buttons are now a uniform height.
* jfx, removed border radius on search input button.

* user-catalogue scheduled refreshes (#399)

* core, adds 'scheduled-user-catalogue-refresh'
  if a catalogue is more than 28 days old, it will trigger an automatic refresh.
* cli, shifted a chunk of refresh-user-catalogue logic into core.
* config, adds preference 'keep-user-catalogue-updated'.
* jfx, adds 'keep user catalogue updated' toggle to preference menu
* updated CHANGELOG

* gui tweaks (#406)

* gui, fixed 'key' column on addon detail raw data was too small for text 'supported game tracks'.
* gui, fixed 'updated' column on installed addons was too small for '12 months ago'
* gui, switch to log tab when user catalogue is manually refreshed

* more stats (#403)

* core, adds a place to collect stats about app state
* core, adds github stats to :db-stats
* gui, replaces stats at bottom of pane with info from :db-stats.
* gui, split pane is now permanently there, which is much faster to toggle.
* gui, split pane now has 'sub-pane' content, defaulting to the notice-logger
* github-stats, fetched no more than once a minute
* db-stats, updated when state changes rather than on refresh
* db-stats, renamed the stats to use keyword namespaces to roughly group them
* http, changed expiry-offset-hours to expiry-offset-minutes
* http, prune cache now clears anything older than http/expiry-offset-minutes + 1
* utils, value formatting shifted out of jfx into utils
* jfx, status bar text switched to a label
* jfx, adds key-vals widget and the db-stats-widget that uses it
* jfx, the key-vals widgets now share the same styling
* jfx, the addon-detail key-vals widget uses the new key and value formatting fns

* utils, added space between bytes value and it's unit

* jfx, 'size' column is now right-aligned

* jfx, 'size' column moved to other side of table
it's now located after created and updated dates but before installed and available versions.
after right-aligning it seemed more at home there

* updated README

* updated README

* removes tukui support (#408)

* removes tukui support

* updated screenshots for v7 (#409)

* updated screenshots for v7

* 7.0.0

---------

Co-authored-by: Torkus <48141663+ogri-la@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant