nicklockwood / SwiftFormat

A command-line tool and Xcode Extension for formatting Swift code
MIT License
7.62k stars 623 forks source link

Update trigger for release action from `created` to `published` #1730

Closed calda closed 2 weeks ago

calda commented 2 weeks ago

The release new action from #1721 didn't trigger properly for 0.54.0.

Right now the job uses a release: [created] trigger. The documentation says:

Note: Workflows are not triggered for the created, edited, or deleted activity types for draft releases. When you create your release through the GitHub browser UI, your release may automatically be saved as a draft.

This is probably the most likely explanation for why it didn't work.

It sounds like the recommended trigger is published rather than created:

on:
  release:
    types: [published]

so this PR updates the trigger. Hopefully now it'll work for 0.54.1!

codecov[bot] commented 2 weeks ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 95.14%. Comparing base (dd989a4) to head (fa9e3e2).

:exclamation: Current head fa9e3e2 differs from pull request most recent head d39b6b8

Please upload reports for the commit d39b6b8 to get more accurate results.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #1730 +/- ## ========================================== - Coverage 95.19% 95.14% -0.06% ========================================== Files 20 20 Lines 22882 22882 ========================================== - Hits 21783 21771 -12 - Misses 1099 1111 +12 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

calda commented 2 weeks ago

Also noticed that the output artifact bundle doesn't seem to support Intel, probably because the --arch argument was wrong.

calda commented 2 weeks ago

Confirmed that change fixed Intel support: https://github.com/airbnb/swift/pull/275. Our style guide repo / formatter tool now uses an artifact bundle created by this CI job.