jidicula / clang-format-action

GitHub Action for clang-format checking
MIT License
98 stars 33 forks source link

Refactor task - use Ubuntu Mantic for `clang-format` versions 13 through 16 #165

Open jidicula opened 1 year ago

jidicula commented 1 year ago

Ubuntu Mantic also contains clang-format versions 13 through 16. As much as possible, I prefer to reduce the number of Ubuntu versions I'm shipping in my Docker images. Switching versions 13 through 16 to Mantic would allow me to drop the Lunar dependency.

This task is fairly simple - in these lines, switch the Ubuntu version to mantic to match version 17.

jidicula commented 1 year ago

@Xav83 if you're looking for some more low-hanging fruit for Hacktoberfest, feel free to take a swing at this ☝️

Ajeets6 commented 1 year ago

Hi,Can you assign this to me?

jidicula commented 1 year ago

Sure thing, thanks @Ajeets6 !

danperkins commented 1 year ago

@jidicula it seems like this image change wasn't entirely backwards compatible for our simple use case:

    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - name: Run clang-format style check for C/C++/Protobuf programs.
        uses: jidicula/clang-format-action@v4.11.0
        with:
          clang-format-version: "16"

Could you revert this change and then push it out again but with a new tag? That at least gives people the ability to opt into it

jidicula commented 1 year ago

@jidicula it seems like this image change wasn't entirely backwards compatible for our simple use case:

    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - name: Run clang-format style check for C/C++/Protobuf programs.
        uses: jidicula/clang-format-action@v4.11.0
        with:
          clang-format-version: "16"

Could you revert this change and then push it out again but with a new tag? That at least gives people the ability to opt into it

@danperkins sorry about that! I've reverted the change in #167 and merged it, so the new images will be built and shipping shortly and your workflows will start functioning again.

What was the specific issue you were seeing with your use-case?

danperkins commented 1 year ago

@jidicula thanks for the quick response! Someone from our team is working through the formatting changes now so that we can move to the new version before too long. It seems like it was just caused by us having the formatting and linting happing in slightly different pipelines. Clang was unhappy with some of the spacing/tabs in our files after the change. I guess we could have tried rolling back to 4.10.0 to see if we could have been stable on that version after 4.11.0 changed.