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

refactor!: core and cli installer #106

Closed
wants to merge 23 commits into from
Closed

refactor!: core and cli installer #106

wants to merge 23 commits into from

Conversation

wangl-cc
Copy link
Member

@wangl-cc wangl-cc commented Nov 22, 2023

Features:

  • Introduce the core-installer feature to disable core installation.

Refactors:

  • Transform find_lib/resource into methods of Dirs.
  • Add a global DIRS variable to avoid pass it everywhere.
  • Move constants to a separate module.

BREAKING CHANGES:

  • Replace the self feature with cli_installer.
  • Make maa update reject updating MaaCore installed at non-standard locations.
  • Change Version JSON files to adopt multiple channels, resembling the version JSON of MaaCore.
  • Remove deprecated field channel in cli.toml.
  • Remove all installer-related environment variables. Users can now specify them either in the configuration file or as command-line arguments.

@wangl-cc wangl-cc force-pushed the refactor/installer branch 6 times, most recently from 8076991 to 147f677 Compare November 22, 2023 11:16
Copy link

codecov bot commented Nov 22, 2023

Codecov Report

Attention: 276 lines in your changes are missing coverage. Please review.

Comparison is base (c915139) 25.96% compared to head (fd587c9) 31.34%.

❗ Current head fd587c9 differs from pull request most recent head 384f737. Consider uploading reports for the commit 384f737 to get more accurate results

Files Patch % Lines
maa-cli/src/installer/maa_core.rs 12.94% 121 Missing ⚠️
maa-cli/src/dirs.rs 27.58% 42 Missing ⚠️
maa-cli/src/installer/maa_cli.rs 32.55% 29 Missing ⚠️
maa-cli/src/main.rs 0.00% 29 Missing ⚠️
maa-cli/src/installer/download.rs 0.00% 16 Missing ⚠️
maa-cli/src/run/mod.rs 0.00% 13 Missing ⚠️
maa-cli/src/installer/version_json.rs 59.09% 9 Missing ⚠️
maa-cli/src/config/cli/maa_cli.rs 73.33% 8 Missing ⚠️
maa-cli/src/installer/extract.rs 0.00% 4 Missing ⚠️
maa-cli/src/config/cli/maa_core.rs 95.23% 2 Missing ⚠️
... and 2 more
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #106      +/-   ##
==========================================
+ Coverage   25.96%   31.34%   +5.38%     
==========================================
  Files          21       24       +3     
  Lines        1606     1745     +139     
==========================================
+ Hits          417      547     +130     
- Misses       1189     1198       +9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

The maa core failed to exit, I have no idea why.
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