Closed
Conversation
Member
|
我觉得本 PR 意义不大,HMCL 并没有一定要使用 zipfs 的理由。 我计划在 3.7.14 中删除对 zipfs 的依赖,这项工作已经在本地进行了一半了。 |
Member
Author
zipfs 相较于 common-compress 有更简单的 API,可以高度简化代码。将 zipfs 迁移到 common-compress 不是一个好主意 例如,如果想要计算相对路径,zipfs 可以这么写 而 common-compress 必须手动对 String 进行处理,没有 resolve 这类工具方法。我看不出忠于 common-compress 除了可以直接获取到文件名的 byte[] 序列外有任何优势 如果可能,我们可以照抄 common-vfs 的写法,在 common-compress 基础上建构 fs 层 API |
…le cannot be implemented with ZipFS. So I did this to prove they are wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
目前 HMCL 依赖 jdk ZipFS。依照在崩溃分析群的观察,部分玩家在使用损坏的 ZipFS 实现时会出现无法解析整合包、模组信息等问题。将这一仅有 120K 的库嵌入 HMCL 中可以解决这一问题,并不再需要面对不同发行版中 zipfs 的不同表现。此外,这将给予我们自定义报错信息等方面更大自由度。