pint.ok --no-color -l debug lint rules
! stdout .
cmp stderr stderr.txt

-- stderr.txt --
level=info msg="Loading configuration file" path=.pint.hcl
level=info msg="File parsed" path=rules/0001.yml rules=2
level=debug msg="Found recording rule" lines=1-2 path=rules/0001.yml record=colo:recording
level=debug msg="Configured checks for rule" enabled=["promql/syntax","alerts/for","alerts/comparison","alerts/template","promql/fragile","promql/regexp","promql/aggregate(job:true)"] path=rules/0001.yml rule=colo:recording
level=debug msg="Found alerting rule" alert=colo:alerting lines=4-5 path=rules/0001.yml
level=debug msg="Configured checks for rule" enabled=["promql/syntax","alerts/for","alerts/comparison","alerts/template","promql/fragile","promql/regexp"] path=rules/0001.yml rule=colo:alerting
rules/0001.yml:2: job label is required and should be preserved when aggregating "^.+$" rules, remove job from without() (promql/aggregate)
 2 |   expr: sum(foo) without(job)

level=info msg="Problems found" Warning=1
-- rules/0001.yml --
- record: "colo:recording"
  expr: sum(foo) without(job)

- alert: "colo:alerting"
  expr: sum(bar) without(job) > 0

-- .pint.hcl --
parser {
  relaxed = ["rules/.*"]
}
rule {
    match {
        kind = "recording"
    }
    aggregate ".+" {
        keep = [ "job" ]
    }
}
