catppuccin / github-file-explorer-icons

🐙 Soothing pastel icons for GitHub File Explorer
https://chromewebstore.google.com/detail/catppuccin-for-github-fil/lnjaiaapbakfhlbjenjkhffcdpoompki
MIT License
91 stars 1 forks source link

ci(build): upload compiled artifact & display job summary #127

Closed uncenter closed 2 months ago

uncenter commented 2 months ago

I think this means we can view the sizes of the artifacts to make sure nothing like https://togithub.com/wxt-dev/wxt/issues/738 happens again. Also just means you can verify/test the files in general.

uncenter commented 2 months ago

There are three zips that I've globbed for (firefox, chrome, and "sources" - the repo contents basically - would be built by the previous steps), I assume they will each be uploaded as a separate artifact? Or are they combined into one zip artifact?

sgoudham commented 2 months ago

I assume they will each be uploaded as a separate artifact? Or are they combined into one zip artifact?

Unfortunately, you always get a wrapper zip with the artifact upload. ref: https://github.com/actions/upload-artifact/issues/39

uncenter commented 2 months ago

I assume they will each be uploaded as a separate artifact? Or are they combined into one zip artifact?

Unfortunately, you always get a wrapper zip with the artifact upload. ref: actions/upload-artifact#39

Argh. Should I upload the directories of the zips isntead of the zip themselves, and individually?

uncenter commented 2 months ago

Ex:

      - name: Upload compiled Chrome extension
        uses: actions/upload-artifact@v4
        with:
          path: dist/chrome-mv3

      - name: Upload compiled Firefox extension
        uses: actions/upload-artifact@v4
        with:
          path: dist/firefox-mv2

Seems cumbersome :/

sgoudham commented 2 months ago

I don't mind the wrapper zip these days and just accept the harsh reality that we live in lol.

You can separate it out into multiple steps if you want, I'd say it's fine in this case cause it's 3 known zips that you're building. It's a lot harder to justify something like all the accents of a Catppuccin flavour.

uncenter commented 2 months ago

Do you know what the assets look like in the UI if you don't provide a name? Does it just use the filename? https://github.com/actions/upload-artifact#inputs says name defaults to artifact so does it just say "artifact"? The latter seems like the worst option so I hope not!

sgoudham commented 2 months ago

I think it does default to artifact, the examples across the organisation all try to provide a name of some sort: https://github.com/search?q=org%3Acatppuccin%20actions%2Fupload-artifact&type=code

uncenter commented 2 months ago

CleanShot 2024-09-08 at 21 22 59

Alright I think this does what I want! Turns out you can add a job summary, so I used that to list the sizes of the output directories (helpful for the sources zip mostly, which I chose not to zip since it is kinda large).