pcdshub / pre-commit-hooks

Pre-commit hooks for PCDS projects (https://pre-commit.com/)
Other
10 stars 7 forks source link

Decide on standard configuration for Beckhoff TwinCAT/PLC projects #2

Closed klauer closed 4 years ago

klauer commented 4 years ago
ZLLentz commented 4 years ago

I think ci-helpers should draw from here, rather than the other way around so we can have one source for the group of them

Either way: we'll want to throw on some custom ones for TwinCAT projects, we've discussed in the past here: https://github.com/pcdshub/pcds-ci-helpers/issues/9

Mostly just targeted xml beautification, banning leading tabs, catching the lineIds...

ZLLentz commented 4 years ago

Hmm, I think I should have started in this repo instead of in ci-helpers this week... It seems like doing the checks before pushing to github would be more useful than waiting for the travis to run. But at least the travis checks for people who didn't configure their pre-commit-hooks.

In order of priority, I want to set this up to:

And then I'll just grab all the pre-commit-hooks standards that seem good, e.g.

I'll look around for hooks that others have written before diving in to writing our own.

klauer commented 4 years ago

Sounds good to me. I wouldn't doubt there's already an XML beautifier one that could be used in place of rolling our own (or using what I had whipped up months ago)

ZLLentz commented 4 years ago

Finding the one you whipped up counts as looking around for hooks that others have written :+1:

We'll probably need to do something ourselves for these anyway since they need to target specific odd filetypes

ZLLentz commented 4 years ago

klauer's pre-commit gist for reference (from slack search) while working on this: https://gist.github.com/klauer/a1489e408042a95ed9e804e37e7832c2