a63cbb0c

Skip a build directory by its whole name, not by a prefix of it

Independent of #11 and #12.

The discovery walk skipped any directory whose name started with `result`, meaning to skip a nix build output:

```haskell
|| "result" `isPrefixOf` name
```

It also skipped one called `results`, and every package under it went missing from discovery **with nothing reported**. That is what makes it worth a PR rather than a line: a walk that finds no cabal file and a walk that refused to look return the same answer to a caller, so the packages simply were not there.

The fixture fails on master with `Right []` where it wants `Right [PackageName "thing"]`. I checked that before keeping the fix.

## Symlinks are followed

An earlier version of this replaced the name test with a symlink test, on the theory that a nix output is a symlink and what is on the far side of one is not this repository's. That was wrong, and wrong in the same way as the bug: a repository that links a package in on purpose has one to find there, and refusing to follow the link loses it just as silently.

It was also unnecessary. What a `result` actually points at holds no cabal file: in this repository right now it is a check output of `facts.db`, `report.json` and `report.txt`, and a nix source derivation is a tarball. So the walk follows it, lists it, finds nothing, and moves on. `hopinion check .` in this working tree, which has a `result` symlink, reports 0 findings and exits 0 with `result` no longer named anywhere.

And inside a Nix build the source is a store path, so build outputs are not in the tree to begin with.

## What it skips now

`dist-newstyle` and `node_modules` by whole name, because they are real directories holding copies of sources that are not the repository's, and anything hidden for the same reason: `.git`, `.stack-work` and `.direnv` all do.

## Testable

`skippedByName :: Path Rel Dir -> Bool` is top-level and exported, where the walk had it in a `where` clause with no signature and no test. It is pure, so the prefix case is a unit test rather than a walk over a fixture.

187 tests, 9 new: the named and hidden cases, four prefix lookalikes, the fixture with a package two levels under `results`, and one over a temp directory asserting a linked-in package is found.

## One thing worth knowing

The fixture needed a line in `.gitignore`. Your global ignore file has `result*`, which hides a directory called `results` exactly the way this walk did — this repository's own `.gitignore` gets it right with `result` and `result-*`. Same bug one level up, and it silently untracks anything named that way in every repository. I have not touched it.

## Review loop

```
nix flake check
nix develop --command cabal test hopinion-test --test-options="--ai-executor"
```

Suite timing

Time to Start Worker time Duration Time to finish Idle
Config 0s 1s 1s 1s 0s
Eval 1s 12s 12s 13s 0s
Build 12s 0s 0s 12s 0s
Suite 0s 13s 13s 13s 0s

Timeline

0s10s