marinofelipe / swift-package-info

Swift CLI tool that provides information about a Swift Package
MIT License
75 stars 7 forks source link

Danger Plugin 🤓 #24

Open Sherlouk opened 3 years ago

Sherlouk commented 3 years ago

Okay, so a bit of a far out there idea... and far from a priority!

But it could be really interesting to see a danger-swift-package-info plugin which builds on this executable.

https://github.com/danger/danger-plugin-template https://danger.systems/guides/creating_your_first_plugin.html

I would expect it to detect all packages in the repository, and calculate the size diff for any package which has changed. It would then formulate a message or warning depending on how much the binary has increased by.

Warning: Binary size for "ContentModels" package has increased by 14% to 65.3 MB

Thresholds could be customisable!

image

marinofelipe commented 3 years ago

Another very interesting idea, @Sherlouk 👍 . I agree a ⚠️ Danger plugin would be very nice and would bring value for a lot of folks/companies out there that have danger integrated to their CI pipeline, I also see us using it @GetYourGuide in the future.

This would be my next priority after #3 and #15, and in the meantime I think we can discuss some draft ideas on how the plugin API and features would look like.