NathanVaughn / webtrees-docker

Up-to-date Docker image for webtrees with all the bells and whistles.
https://hub.docker.com/r/nathanvaughn/webtrees
MIT License
64 stars 15 forks source link

Better setup wizard #109

Closed NathanVaughn closed 2 years ago

NathanVaughn commented 2 years ago

Support DB verification certificates: https://github.com/fisharebest/webtrees/blob/f9a3af650116d75f1a87f454cabff5e9047e43f3/app/Http/Middleware/UseDatabase.php#L71-L82

Rewrite a ton of initialization logic to be more extensible

sourcery-ai[bot] commented 2 years ago

Sourcery Code Quality Report

✅  Merging this PR will increase code quality in the affected files by 14.27%.

Quality metrics Before After Change
Complexity 12.07 🙂 5.24 ⭐ -6.83 👍
Method Length 84.62 🙂 86.22 🙂 1.60 👎
Working memory 13.33 😞 8.22 🙂 -5.11 👍
Quality 50.98% 🙂 65.25% 🙂 14.27% 👍
Other metrics Before After Change
Lines 315 433 118
Changed files Quality Before Quality After Quality Change
docker-entrypoint.py 50.98% 🙂 65.25% 🙂 14.27% 👍

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
docker-entrypoint.py enable_apache_site 10 🙂 205 ⛔ 12 😞 44.70% 😞 Try splitting into smaller methods. Extract out complex expressions
docker-entrypoint.py setup_wizard 9 🙂 244 ⛔ 11 😞 44.91% 😞 Try splitting into smaller methods. Extract out complex expressions
docker-entrypoint.py get_environment_variable 11 🙂 138 😞 11 😞 51.72% 🙂 Try splitting into smaller methods. Extract out complex expressions
docker-entrypoint.py update_config_file 4 ⭐ 159 😞 8 🙂 62.28% 🙂 Try splitting into smaller methods

Legend and Explanation

The emojis denote the absolute quality of the code:

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Help us improve this quality report!