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

实现 #2969: 启动前日志列出mods目录的jar文件 #3125

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

burningtnt
Copy link
Member

Close #2969

@Glavo
Copy link
Member

Glavo commented Jun 23, 2024

你想修改可以向他的 PR 分支提出新的 PR,不要把别人的 PR 关了然后自己拿来开 PR。

@burningtnt
Copy link
Member Author

burningtnt commented Jun 23, 2024

你想修改可以向他的 PR 分支提出新的 PR,不要把别人的 PR 关了然后自己拿来开 PR。

当事人的 PR 提供的代码已经几乎被全部移除。介于当事人的努力依然值得尊重,我并没有完全在 Git 层面移除他的提交。因此,当本 PR 合并后,当事人依然会有 Co-Author 信息

EDIT: 换而言之,这不是修改,而是重写

Copy link
Contributor

@3gf8jv4dv 3gf8jv4dv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I tested the refactored code and it looks good.

Thanks to the fact that the log files are stored in UTF-8 encoding, CJK characters can also be displayed normally. For disabled mods, mods replaced during updates, and mods with different suffixes (tested with .zip and .litemod), they can also be displayed normally.

@burningtnt
Copy link
Member Author

burningtnt commented Jun 26, 2024

Thanks for your testing.

Using Files.walkFileTree, which is an API from standard java library could prevent potential bugs or risks from using Files.listFiles. And, with this structure, it's easies to list files from .zip files with less edit.

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.

[Feature] 建议在启动器日志中打印 mods 文件夹里的文件和子文件夹(参考 MultiMC)
4 participants