73 Commits

Author SHA1 Message Date
comp500
f05bbe1dd4 Merge branch 'main' into pr/unascribed/258 2024-08-28 18:53:47 +01:00
Keith
7b4be47578
Update modrinth url regex to accept 'www.' as well (#304) 2024-05-27 20:54:22 +01:00
James Groom
9cca74476d
Improve r13y of packwiz modrinth export by sorting manifestFiles (#287)
resolves #244
2024-04-21 12:46:33 +01:00
Una Thompson
e1508134c7
Prefer SHA-512 for Modrinth, add rehash command 2023-10-03 18:41:48 -07:00
comp500
ef049968b1
Fix incorrect usage of slices.Compact (fixes #257) 2023-09-23 21:52:23 +01:00
comp500
4c23e264b0 Clean up code, filter version numbers for NeoForge as well as Forge
NeoForge doesn't seem to have an update checker JSON yet, so we can't determine
the recommended version
2023-07-30 15:09:18 +01:00
comp500
234f927be9 Support NeoForge as a loader (compatible with Forge mods)
TODO: implement support in migrate command
2023-07-30 14:56:11 +01:00
comp500
38dcc505e5 Add NeoForge to Modrinth version filtering 2023-07-30 14:56:11 +01:00
comp500
99d0af14c4 Fix duplicates in Modrinth dependency lookups 2023-07-02 14:38:10 +01:00
comp500
d018d7e780 Fix download warning print loops 2023-06-23 18:22:02 +01:00
comp500
4fb1f1b59d Index fixes and performance improvements (fixes #223, #224)
- Fixed creation of duplicate index entries when importing from CurseForge (fixes #224)
- Automatically remove duplicates in index
- Fixed `packwiz serve` with a custom `--pack-root` argument (fixes #223)
- Fixed `packwiz serve` with a custom index.toml location
- Cleaned up internal serving code, added comments and better errors
- Refactored path handling code
- Improved refreshing/exporting performance
- Factored out duplicated exporting logic
- Replaced GetAllMods calls with cleaner LoadAllMods calls and made the former private
- Improved variable names in update command
- Improved handling of aliassed files
- Changed CheckUpdate to take references to metadata
- Removed the ability to use an absolute path to the index file (that probably didn't work anyway)
- Behaviour change: order of entries in exported files may be random
2023-05-29 23:15:55 +01:00
comp500
d25817273b Fix Modrinth URL version number precedence (oldest-first) 2023-05-21 16:35:26 +01:00
comp500
e966eaffc0 Manually replace FLK deps with QKL when using Quilt >=1.19.2 (fixes #212) 2023-04-13 17:12:44 +01:00
comp500
bd71ad5679 Manually replace FAPI deps with QFAPI/QSL when using Quilt (fixes #212) 2023-04-13 16:45:10 +01:00
comp500
06f9204cd4 Fix Quilt+Fabric files from Modrinth being preferred over Fabric (fixes #208) 2023-04-12 23:24:34 +01:00
Matt Artist
a344ba11ba
Add a command for changing the acceptable versions (#206)
* feat: add packwiz settings command to allow for changing acceptable versions

* Add deduping on the list

* Fix typo in comment

* Detect out of order list and give the user an option to correct it

* Support adding and removing specific versions

* Ensure the options aren't nil

* Clean up the slice removal boilerplate

* Fix usage of slices.Delete
2023-04-08 19:00:40 +01:00
comp500
8d50b97356 Fix Modrinth searches taking the first argument as a slug 2023-03-16 13:42:20 +00:00
comp500
433218e3cf Make most Modrinth dep errors non-fatal, improve err message (fixes #201) 2023-03-15 02:41:46 +00:00
comp500
aeae76a569 Linter fixes (error handling, unused constants, raw strings) 2023-03-10 17:06:48 +00:00
comp500
da04eb7f13 Regression fix: filter Modrinth search results by game versions 2023-03-10 16:47:18 +00:00
comp500
42d8370d0c Latest version fixes: correctly order preferences (fixes #198)
Both CurseForge and Modrinth preferences were not being done in a specific order - so
a file with a newer Minecraft version would not necessarily take priority over a file
with a more preferred loader (e.g. Quilt over Fabric) or a file with a newer release
date / CurseForge ID.
Also fixed a loop variable reference in the CurseForge loop, which caused eagerly resolved
(included in API response) file info to be inconsistent with the chosen version, and
added filtering for duplicate values in the acceptable-game-versions/primary version list
to ensure game versions are always compared properly (so the same index == same version).
2023-03-10 16:35:34 +00:00
comp500
d38d279d98 Prefer game versions according to acceptable versions list (fixes #181)
The acceptable versions list should now be specified in order of preference, where the last version is the most preferable Minecraft version
2023-02-14 16:10:06 +00:00
comp500
d667447a88 Compare Modrinth versions by release date, warn if inconsistent with version numbers 2023-02-14 12:16:24 +00:00
comp500
79d3ed3957 Reword "mod"/"addon"/"install" to clearer terms across all commands (fixes #138) 2023-01-20 18:39:23 +00:00
comp500
945a608112 Modrinth: add support for Canvas shaders 2023-01-20 17:13:40 +00:00
comp500
44f562927c Change datapack-path to datapack-folder 2023-01-20 06:45:19 +00:00
comp500
d57140c33a Modrinth: version number resolution (fixes #103) 2023-01-20 05:39:36 +00:00
comp500
c596179c5c Modrinth: fix loader folder lookup 2023-01-20 04:54:31 +00:00
comp500
66bf34c1c2 Modrinth: rename url categories list to be clearer 2023-01-20 04:53:23 +00:00
comp500
f3963ec169 Modrinth: detect default meta-folder, prefer mods to datapacks
Requires specifying datapack-path option to install datapacks (as the location varies between datapack loader mods)
2023-01-20 04:51:04 +00:00
comp500
8937960d52 Modrinth: Parse non-mod and CDN URLs, bring more in line with CF impl 2023-01-17 04:51:47 +00:00
comp500
497585c38a Use FlexVer instead of semver for comparing Modrinth version numbers 2022-11-19 21:39:59 +00:00
comp500
4f6528dcb5 Fix Modrinth exports of external files with omitted side field 2022-10-30 04:52:09 +00:00
comp500
f00dc9844f Allow any path under a Modrinth mod page 2022-10-11 01:19:04 +01:00
Tricked
c7c2ca786b
feat: add command for arbitrary URLs (#137)
* feat: install command for direct downloads

* use sha1 instead of sha256

* apply suggestions

* feat: parse urls instead of using hasprefix

* stop by default and add force flag

* Implement various fixes and improvements

Co-authored-by: Tricked <72335827+SkyBlockDev@users.noreply.github.com>
Co-authored-by: comp500 <comp500@users.noreply.github.com>
2022-08-27 00:08:25 +01:00
comp500
11671421ac -y/--yes flag for non-interactive mode (fixes #46)
Also makes Modrinth auto-accept search results with only 1 result, to be
consistent with CurseForge.
2022-08-25 04:47:18 +01:00
comp500
503232a3fa Implement dependency support for Modrinth (fixes #56) 2022-08-25 03:48:34 +01:00
comp500
044c34e07c Move to go-modrinth lib (v2 API) and always supply UA in HTTP requests 2022-08-02 02:53:31 +01:00
comp500
d5290ebd32 Eradicate variable-size integer types where not used by interface or as index (fixes #107) 2022-06-16 21:32:15 +01:00
comp500
b8be3784f6 Improve Modrinth command errors 2022-06-08 23:36:15 +01:00
comp500
65688cf2b1 Prefer Quilt mods to Fabric mods when using Quilt (Modrinth-only) 2022-06-08 22:39:15 +01:00
comp500
f533e677ca Merge duplicate getLoaders methods into single core method 2022-06-08 22:34:50 +01:00
Jamie Mansfield
57b554d5e3
Add flag to disable Modrinth restricted domains (#126)
* Update list of Modrinth approved domains

* Add flag to disable Modrinth restricted domains

This allows packwiz to produce .mrpack files with direct downloads,
for packs that aren't distributed on modrinth.com.
2022-06-02 17:40:51 +01:00
comp500
dae133b73c Completed download implementation for Modrinth export 2022-05-21 05:00:21 +01:00
comp500
55f0e4a297 WIP: misc fixes, start updating CF/MR export to use download system 2022-05-20 18:13:43 +01:00
comp500
3a6109c1f9 Merge branch 'master' into wip/new-curseforge-api 2022-05-17 01:07:04 +01:00
comp500
0f3096e251 Use the correct directories for non-mod files; use .pw.toml extension
The mods-folder option is now replaced with two new options: meta-folder and meta-folder-base
This allows non-mod files to use the correct directory based on their category; with correct
import of resource packs/etc from CurseForge packs, and the ability to override this behaviour.
To improve the reliability of packwiz metadata file marking (in the index), new files now use .pw.toml
as the extension - any extension can be used, but .pw.toml will now be automatically be
marked as a metafile regardless of folder, so you can easily move metadata files around.
Existing metadata files will still work (as metafile = true is set in the index); though in
the future .pw.toml may be required.
2022-05-16 21:06:10 +01:00
comp500
2073e4475e Support Modrinth modpack fileSize field and sha512 hash 2022-05-16 01:15:12 +01:00
comp500
f1eb34d444 Quilt support 2022-04-20 20:58:49 +01:00
comp500
cdd737839d Automatically download and bundle unwhitelisted mods/files in Modrinth modpacks 2022-03-29 01:02:24 +01:00