File: Regression_in___96__find_--json__96___output.mdwn

package info (click to toggle)
git-annex 10.20230126-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 69,344 kB
  • sloc: haskell: 74,654; javascript: 9,103; sh: 1,304; makefile: 203; perl: 136; ansic: 44
file content (35 lines) | stat: -rw-r--r-- 942 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
As of 436f10771 (make CommandStart return a StartMessage, 2019-06-06),
`find --json` no longer outputs json.

For example, with

[[!format sh """
cd $(mktemp -dt gx-find-json-XXXXXXX)
git init && git annex init
echo one >one && git annex add one && git commit -mone
git annex find --json -- one
"""]]

the last command outputs

```
one
```

rather than

```
{"bytesize":"4","mtime":"unknown","keyname":"2c8b08da5ce60398e1f19af0e5dccc744df274b826abe585eaba68c525434806","backend":"SHA256E","key":"SHA256E-s4--2c8b08da5ce60398e1f19af0e5dccc744df274b826abe585eaba68c525434806","humansize":"4 B","hashdirmixed":"0J/J1/","file":"one","hashdirlower":"171/8dc/"}
```

436f10771 appears to touch a lot of things, so perhaps other commands
show similar issues and `find` is just the first I noticed.

### On what operating system?

GNU/Linux, building git-annex with Guix

[[!meta author=kyle]]
[[!tag projects/repronim]]

> [[fixed|done]] --[[Joey]]