Skip to content

Commit

Permalink
7.4.0 (#432)
Browse files Browse the repository at this point in the history
* support multiple 'interface' values in .toc files (#430)
* toc.clj, introduces 'interface-version-list' field.
 it contains all possible interface versions parsed from the 'interface' field.
* toc.clj, split 'parse-addon-toc' into '-parse-addon-toc'.
  new private fn is less strict, interpreting and extrapolating values, warning on bad values etc.
  new fn does validation and discards data if it's invalid.
  this was done so we don't have to repeat parsing steps elsewhere.
* toc.clj, the templated '## # interface' value is now considered and included in the interface-version-list.
* github-api.clj, removed duplicated parsing of :interface values in favour of that in toc.clj
* github-api.clj, order of extracted gametrack values is now deterministic.
* utils, fixed bug in interface-version-to-game-version
 '110000' was returning '1.0.000' instead of '11.0.0'
* toc.clj, fixed bug where data would fail to validate and be discarded.
 it was possible for multiple distinct interface-version values to become duplicate game tracks values (like [:retail :retail])
* jfx.clj, the 'WoW' (interface version) column now supports multiple values.
 default column width values increased to accommodate them.
* specs.clj, replaces toc :interface-version with :interface-version-list
* core.clj, fixed a typo in the import/export logic and the test helper that was using :toc/game-track instead of :-toc/game-track
* toc.clj, replaced :-toc/game-track with :-toc/game-track-list
* addon.clj, a single set of toc data can now belong to many game tracks
 this means the first instance of 'classic' toc data (for example) will be used even if multiple toc files support classic. crazy.
* tukui, curseforge, removed their 'expand-summary' implementations as they were using :interface-version
* jfx.clj, addon data detail pane now accommodates many interface values.
* toc.clj, removed a warning when the presence of a game track in the filename doesn't match the game tracks parsed from the data.
 the user can't really do anything about it, I had at least one false-positive and with many game tracks to now check it seems needlessly expensive.
* curseforge, tukui, removes test fixtures referenced by removed code.
* catalogue.clj, fixed possibilty of multiple game tracks in toc2summary
* specs, source-updates, removes 'release-label' and 'interface-version'.
 these appear to have been introduced for curseforge and only used there.
* deps bump
* constants, adds entries for Dragonflight patch releases.
* constants, adds entry for The War Within.
* replaces references to old wiki with new wiki.
* linted
  • Loading branch information
torkus authored Jul 19, 2024
1 parent 98aa237 commit b5e69ca
Show file tree
Hide file tree
Showing 47 changed files with 636 additions and 7,378 deletions.
33 changes: 33 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,39 @@ All notable changes to this project will be documented in this file. This change
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## 7.4.0 - 2024-07-19

### Added

* added support for parsing multiple interface version values from .toc file.
- a single .toc file may now yield multiple possible game tracks (retail, classic, wrath, etc).
* added entries to the known patch list for the recent major Dragonflight patches and The War Within.

### Changed

* the WoW column in the GUI now supports displaying multiple game versions (like 8.0, 9.0, 10.0).
- these are derived from interface versions (80000, 90000, 100000).
* the raw data GUI widget in the addon details pane now supports displaying multiple interface versions.
* replaced references to the old wiki with the new wiki (warcraft.wiki.gg).
* bumped dependencies.

### Fixed

* fixed a typo in a field name in the import/export logic.
* fixed a bug in the interface-version => game-version logic where 110000 was returned as '1.0.000' instead of '11.0.0'.

### Removed

* removed curseforge and tukui test fixtures and the fetching of test fixtures.
* removed support for 'release labels' attached to addon source updates.
- only supported by curseforge and provided a friendlier label for a release than a version number.
* removed more curseforge and tukui logic that was disabled many releases ago.
* removed support for interface versions in .toc files containing non-numeric values.
- for example, "30008a" which used to parse to "3.0.8a".
- the interface version for these alpha and beta releases don't actually have 'a' and 'b' suffixes.
- https://warcraft.wiki.gg/wiki/Patch_3.0.8a
- https://warcraft.wiki.gg/wiki/Patch_8.1.0a

## 7.3.0 - 2024-04-23

### Added
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ the same addon directory. If an addon is available for multiple addon systems it
* `classic (Cata)` will prefer `classic (Cata)` addons, then `classic (WotLK)`, then `classic (TBC)`, then `classic` then `retail`

If uncertain which addon system an installed addon supports, look at the `WoW` column value on the `installed` tab and
compare it to the `Version` value in the list of WoW [public client builds](https://wowpedia.fandom.com/wiki/Public_client_builds).
compare it to the `Version` value in the list of WoW [public client builds](https://warcraft.wiki.gg/wiki/Public_client_builds).

### install addons from URL

Expand Down Expand Up @@ -413,12 +413,12 @@ Prior to `1.0.0`, Strongbox was known as "wowman". The [AUR package](https://aur

Moved here: **https://ogri-la.github.io/wow-addon-managers/**

Last updated: **2023-08-13**
Last updated: **2024-05-07**

[Request a change](https://github.com/ogri-la/strongbox-comrades/issues).

## License

Copyright © 2018-2023 Torkus
Copyright © 2018-2024 Torkus

Distributed under the GNU Affero General Public Licence, version 3 [with additional permissions](LICENCE.txt#L665)
17 changes: 5 additions & 12 deletions TODO.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,22 +6,15 @@ see CHANGELOG.md for a more formal list of changes by release

## done

* rename `strongbox` release to `strongbox.AppImage`
- re-submit
- update release scripts
- done
- https://appimage.github.io/strongbox/

* update release script
- update references from 'strongbox' to 'strongbox.AppImage'
- done

* cataclysm classic support
- done
* support multiple interface values
* bump any game versions
* bump any deps

## todo


## todo bucket (no particular order)
* remove support for parsing templated .toc keyvals: '# ## Key: Value'

* gui, 'set-icon' is taking a long time to do it's thing.

Expand Down
15 changes: 0 additions & 15 deletions manage.sh
Original file line number Diff line number Diff line change
Expand Up @@ -74,15 +74,6 @@ elif test "$cmd" = "update-test-fixtures"; then
echo "$fname"
}

# curseforge
dl "https://www.curseforge.com/wow/addons?filter-sort=name&page=1" "curseforge-addon-summary-listing.html"

# curseforge api
dl "https://addons-ecs.forgesvc.net/api/v2/addon/327019" "curseforge-api-addon--everyaddon.json"
cp "test/fixtures/curseforge-api-addon--everyaddon.json" "test/fixtures/curseforge-api-addon--everyotheraddon.json"
## one search result
dl "https://addons-ecs.forgesvc.net/api/v2/addon/search?gameId=1&index=0&pageSize=1&searchFilter=&sort=2" "curseforge-api-search--truncated.json"

# wowinterface
dl "https://wowinterface.com/addons.php" "wowinterface-category-list.html"
dl "https://www.wowinterface.com/downloads/cat19.html" "wowinterface-category-page.html"
Expand All @@ -107,12 +98,6 @@ elif test "$cmd" = "update-test-fixtures"; then
dl "https://gitlab.com/api/v4/projects/thing-engineering%2Fwowthing%2Fwowthing-collector/repository/blobs/125c899d813d2e11c976879f28dccc2a36fd207b" "gitlab-repo-blobs--wowthing.json"
dl "https://gitlab.com/api/v4/projects/woblight%2Fnitro/repository/tree" "gitlab-repo-tree--woblight-nitro.json"

# tukui api
dl "https://www.tukui.org/api.php?addon=98" "tukui--addon-details.json"
dl "https://www.tukui.org/api.php?classic-addon=13" "tukui--classic-addon-details.json"
dl "https://www.tukui.org/api.php?ui=tukui" "tukui--tukui-addon-proper.json"
dl "https://www.tukui.org/api.php?ui=elvui" "tukui--elvui-addon-proper.json"

# user-catalogue
dl "https://api.github.com/repos/Stanzilla/AdvancedInterfaceOptions/releases" "user-catalogue--github.json"

Expand Down
14 changes: 7 additions & 7 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<groupId>ogri-la</groupId>
<artifactId>strongbox</artifactId>
<packaging>jar</packaging>
<version>7.3.0</version>
<version>7.4.0</version>
<name>strongbox</name>
<description>World Of Warcraft Addon Manager</description>
<url>https://github.com/ogri-la/strongbox</url>
Expand All @@ -18,7 +18,7 @@
<url>https://github.com/ogri-la/strongbox</url>
<connection>scm:git:git://github.com/ogri-la/strongbox.git</connection>
<developerConnection>scm:git:ssh://[email protected]/ogri-la/strongbox.git</developerConnection>
<tag>86204296a94b4e5b4621bd143daa693f1f4934de</tag>
<tag>822521feaf85c7579ac3ecff6eb849e91abbed94</tag>
</scm>
<build>
<sourceDirectory>src</sourceDirectory>
Expand Down Expand Up @@ -78,7 +78,7 @@
<dependency>
<groupId>org.clojure</groupId>
<artifactId>clojure</artifactId>
<version>1.11.2</version>
<version>1.11.3</version>
</dependency>
<dependency>
<groupId>org.clojure</groupId>
Expand Down Expand Up @@ -108,7 +108,7 @@
<dependency>
<groupId>clj-http</groupId>
<artifactId>clj-http</artifactId>
<version>3.12.3</version>
<version>3.13.0</version>
</dependency>
<dependency>
<groupId>clj-commons</groupId>
Expand All @@ -128,7 +128,7 @@
<dependency>
<groupId>org.flatland</groupId>
<artifactId>ordered</artifactId>
<version>1.15.11</version>
<version>1.15.12</version>
</dependency>
<dependency>
<groupId>clojure.java-time</groupId>
Expand All @@ -148,7 +148,7 @@
<dependency>
<groupId>cljfx</groupId>
<artifactId>cljfx</artifactId>
<version>1.8.0</version>
<version>1.9.0</version>
<exclusions>
<exclusion>
<artifactId>javafx-web</artifactId>
Expand Down Expand Up @@ -219,7 +219,7 @@
<dependency>
<groupId>org.ocpsoft.prettytime</groupId>
<artifactId>prettytime</artifactId>
<version>5.0.7.Final</version>
<version>5.0.9.Final</version>
</dependency>
<dependency>
<groupId>org.controlsfx</groupId>
Expand Down
12 changes: 6 additions & 6 deletions project.clj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
(defproject ogri-la/strongbox "7.3.0"
(defproject ogri-la/strongbox "7.4.0"
:description "World Of Warcraft Addon Manager"
:url "https://github.com/ogri-la/strongbox"
:license {:name "GNU Affero General Public License (AGPL)"
Expand All @@ -11,23 +11,23 @@
;; https://github.com/technomancy/leiningen/issues/2769
:pedantic? false

:dependencies [[org.clojure/clojure "1.11.2"]
:dependencies [[org.clojure/clojure "1.11.3"]
[org.clojure/tools.cli "1.1.230"] ;; cli arg parsing
[org.clojure/tools.namespace "1.5.0"] ;; reload code
[org.clojure/data.json "2.5.0"] ;; json handling
[orchestra "2021.01.01-1"] ;; improved clojure.spec instrumentation
;; see lein deps :tree
[com.taoensso/timbre "6.5.0"] ;; logging
[clj-http "3.12.3"] ;; better http slurping
[clj-http "3.13.0"] ;; better http slurping
[clj-commons/fs "1.6.311"] ;; file system wrangling
[slugify "0.0.1"]
[trptcolin/versioneer "0.2.0"] ;; version number wrangling. it's more involved than you might suspect
[org.flatland/ordered "1.15.11"] ;; better ordered map
[org.flatland/ordered "1.15.12"] ;; better ordered map
[clojure.java-time "1.4.2"] ;; date/time handling library, https://github.com/dm3/clojure.java-time
[envvar "1.1.2"] ;; environment variable wrangling
[tolitius/lasync "0.1.25"] ;; better parallel processing

[cljfx "1.8.0" :exclusions [org.openjfx/javafx-web
[cljfx "1.9.0" :exclusions [org.openjfx/javafx-web
org.openjfx/javafx-media]]
[cljfx/css "1.1.0"]

Expand All @@ -45,7 +45,7 @@

;; GPLv3 compatible dependencies.
;; these don't need an exception in LICENCE.txt
[org.ocpsoft.prettytime/prettytime "5.0.7.Final"] ;; Apache 2.0 licenced, pretty date formatting
[org.ocpsoft.prettytime/prettytime "5.0.9.Final"] ;; Apache 2.0 licenced, pretty date formatting
[org.controlsfx/controlsfx "11.2.1"] ;; BSD-3

;; remember to update the LICENCE.txt
Expand Down
10 changes: 5 additions & 5 deletions src/strongbox/addon.clj
Original file line number Diff line number Diff line change
Expand Up @@ -175,13 +175,13 @@
(logging/with-addon {:dirname (-> addon-dir fs/base-name str)}
(let [toc-data-list (toc/parse-addon-toc-guard addon-dir)]
(if (= 1 (count toc-data-list))
;; whatever toc data we have, we only have 1 of it (normal case), so return that
(-> toc-data-list first (dissoc :-toc/game-track))
;; we only have 1 set of .toc data, so return that
(-> toc-data-list first (dissoc :-toc/game-track-list))

;; we have multiple sets of toc data to choose from. which to choose?
;; we have multiple sets of .toc data to choose from. which to choose?
;; prefer the one for the given `game-track`, if it exists, otherwise do as we do with
;; the catalogue and use a list of priorities.
(let [grouped-toc-data (group-by :-toc/game-track toc-data-list)
(let [grouped-toc-data (utils/group-by-coll :-toc/game-track-list toc-data-list)
safe-fallback [game-track]
priorities (get constants/game-track-priority-map game-track safe-fallback)
group (utils/first-nn #(get grouped-toc-data %) priorities)]
Expand All @@ -193,7 +193,7 @@
(not (apply = group)))
(debug (format "multiple sets of different toc data found for %s. using first." game-track)))

(-> group first (dissoc :-toc/game-track)))))))
(-> group first (dissoc :-toc/game-track-list)))))))

(defn-spec load-all-installed-addons :addon/toc-list
"reads and merges the toc data and the nfo data from *all* addons in the given `install-dir`, groups them and returns the grouped mooshed data."
Expand Down
18 changes: 12 additions & 6 deletions src/strongbox/catalogue.clj
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,11 @@
does *not* support ignoring disabled hosts, see `expand-summary`.
returns `nil` when no release found."
[addon :addon/expandable, game-track ::sp/game-track]
(let [dispatch-map {"curse" curseforge-api/expand-summary
(let [dispatch-map {;;"curse" curseforge-api/expand-summary ;; 2024-07-15: removed
"wowin" wowinterface-api/expand-summary
"gitla" gitlab-api/expand-summary
"githu" github-api/expand-summary
"tukui" tukui-api/expand-summary
;;"tukui" tukui-api/expand-summary ;; 2024-07-15: removed
nil (fn [_ _] (error "malformed addon:" (utils/pprint addon)))}
key (utils/safe-subs (:source addon) 5)]
(try
Expand All @@ -38,9 +38,7 @@
(strongbox.addon/find-pinned-release (assoc addon :release-list release-list)))
source-updates (or pinned-release latest-release)]
(when source-updates
(-> addon
(merge source-updates {:release-list release-list})
(dissoc :release-label)))))
(merge addon source-updates {:release-list release-list}))))
(catch Exception e
(error e (utils/reportable-error "unexpected error attempting to expand addon summary"))))))

Expand Down Expand Up @@ -104,7 +102,15 @@
syn (if (= (:source toc) "wowinterface")
(cond
(:installed-game-track toc) (assoc syn :game-track-list [(:installed-game-track toc)])
(:interface-version toc) (assoc syn :game-track-list [(utils/interface-version-to-game-track (:interface-version toc))])

(not (empty? (:interface-version-list toc)))
(assoc syn :game-track-list
(->> toc
:interface-version-list
(map utils/interface-version-to-game-track)
distinct
vec))

:else sink)
syn)

Expand Down
17 changes: 10 additions & 7 deletions src/strongbox/constants.clj
Original file line number Diff line number Diff line change
Expand Up @@ -4,18 +4,18 @@

(def release-of-previous-expansion
"'Shadowlands', released October 13, 2020. Used to shorten the 'full' catalogue.
https://wowpedia.fandom.com/wiki/Public_client_builds"
https://warcraft.wiki.gg/wiki/Public_client_builds"
"2018-08-14T00:00:00Z")

(def release-of-wow-classic
"the date wow classic went live (addon development may have started before that). Used to guess possible game tracks when it's ambiguous.
https://wowpedia.fandom.com/wiki/Public_client_builds
https://warcraft.wiki.gg/wiki/Public_client_builds
https://worldofwarcraft.com/en-us/news/22990080/mark-your-calendars-wow-classic-launch-and-testing-schedule"
"2019-08-26T00:00:00Z")

;; used as a placeholder for an addon's supported version when we're forced to guess.
;; don't fret too much about patch versions. These values don't affect much.
;; https://wowpedia.fandom.com/wiki/Public_client_builds
;; https://warcraft.wiki.gg/wiki/Public_client_builds
(def latest-retail-game-version "10.0.0")
(def latest-classic-game-version "1.14.3")
(def latest-classic-tbc-game-version "2.5.4")
Expand Down Expand Up @@ -87,9 +87,14 @@
(def tukui-cutoff-label "June 1st, 2023")

(def releases
"https://wowpedia.fandom.com/wiki/Patch"
"https://warcraft.wiki.gg/wiki/Patch"

{"10.2" "Dragonflight: Guardians of the Dream"
{"11.0.0" "The War Within"

"10.2.7" "Dragonflight: Dark Heart"
"10.2.6" "Dragonflight: Plunderstorm"
"10.2.5" "Dragonflight: Seeds of Renewal"
"10.2" "Dragonflight: Guardians of the Dream"
"10.1" "Dragonflight: Embers of Neltharion"
"10.0" "Dragonflight"

Expand All @@ -108,7 +113,6 @@
"7" "Legion"

"6.2" "Warlords of Draenor: Fury of Hellfire"
;; "6.1" "'Garrisons Update'" ?
"6" "Warlords of Draenor"

"5.4" "Mists of Pandaria: Siege of Orgrimmar"
Expand All @@ -129,7 +133,6 @@

"2.4" "The Burning Crusade: Fury of the Sunwell"
"2.3" "The Burning Crusade: The Gods of Zul'Aman"
;; "2.2" "'Voice Chat!'" ?
"2.1" "The Burning Crusade: Black Temple"
"2" "The Burning Crusade"

Expand Down
4 changes: 2 additions & 2 deletions src/strongbox/core.clj
Original file line number Diff line number Diff line change
Expand Up @@ -1593,8 +1593,8 @@
;; 2020-06: dirname must be a non-empty string
;; todo: why is dirname needed here?
:dirname addon/dummy-dirname
:interface-version constants/default-interface-version
:toc/game-track :retail
:interface-version-list [constants/default-interface-version]
:-toc/game-track-list [:retail]
:supported-game-tracks []
:installed-version "0"}
addon-list (map #(merge padding %) addon-list)
Expand Down
Loading

0 comments on commit b5e69ca

Please sign in to comment.