Elm-format: Ignore files inside elm-stuff directory

Created on 15 Aug 2017  路  9Comments  路  Source: avh4/elm-format

If I run something like elm-format --validate . at the command prompt inside a typical Elm project directory, I get a flood of messages about Elm source files inside the elm-stuff directory. I can use elm-format --validate src to just check my own source files, but that doesn't work for stuff like example and test directories that don't have a separate src subdirectory.

Ideally, I think any elm-stuff directories should just be ignored - I'd love to able to just do stuff like elm-format --validate . in the parent directory of all of my various Elm project directories to search all of them simultaneously for files that have not been updated!

bug help wanted Windows

All 9 comments

I should have mentioned that I'm on Windows using elm-format 0.7.0-exp. Is there something I can do to help debug? It does seem to ignore .git directories, so it's odd that it recurses into elm-stuff...

Is anyone able to still reproduce this?

I'm still getting the issue but then I'm still on 0.7.0-exp...is there a more recent version I should be trying?

0.7.0-exp is fine for checking on this, thanks.

At the moment, I haven't been able to get a windows environment going that can actually run Elm and elm-format, so if anyone can help debug, please do!

I'm wondering if it might be

https://github.com/avh4/elm-format/blob/021b55a06c55a0cb72acc73a3f56968ab4098f76/src/ElmFormat/Filesystem.hs#L66

messing up since Windows uses '\' instead of '/' as a directory separator...I can try to take some time to build and test elm-format on my own machine to check at some point.

Sounds like a good theory. Is it also recursing into node_modules and .git folders?

@ianmackenzie In about 15 minute from now, there should be a build of an attempted fix available. You should be able to download the binary from here: https://ci.appveyor.com/project/avh4/elm-format/build/1.0.259/artifacts

Can you try it out and see if it fixes the problem?

Argh, I wish I had noticed that comment before downloading Stack and compiling elm-format from source =)

But yes, I downloaded the new binary and that seems to have fixed the issue - thanks!

(And just for completeness, yes, it was indeed previously also recursing into node_modules and .git.)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

conradwt picture conradwt  路  8Comments

rtfeldman picture rtfeldman  路  4Comments

avh4 picture avh4  路  4Comments

gabrielflorit picture gabrielflorit  路  7Comments

ahstro picture ahstro  路  4Comments