@@ -14,6 +14,21 @@ is a JSON object with the following fields:
1414 The name of the derivation.
1515 This is used when calculating the store paths of the derivation's outputs.
1616
17+ * ` version ` :
18+ Must be ` 3 ` .
19+ This is a guard that allows us to continue evolving this format.
20+ The choice of ` 3 ` is fairly arbitrary, but corresponds to this informal version:
21+
22+ - Version 0: A-Term format
23+
24+ - Version 1: Original JSON format, with ugly ` "r:sha256" ` inherited from A-Term format.
25+
26+ - Version 2: Separate ` method ` and ` hashAlgo ` fields in output specs
27+
28+ - Verison 3: Drop store dir from store paths, just include base name.
29+
30+ Note that while this format is experimental, the maintenance of versions is best-effort, and not promised to identify every change.
31+
1732* ` outputs ` :
1833 Information about the output paths of the derivation.
1934 This is a JSON object with one member per output, where the key is the output name and the value is a JSON object with these fields:
@@ -52,7 +67,6 @@ is a JSON object with the following fields:
5267 > ``` json
5368 > "outputs": {
5469 > "out": {
55- > "path": "/nix/store/2543j7c6jn75blc3drf4g5vhb1rhdq29-source",
5670 > "method": "nar",
5771 > "hashAlgo": "sha256",
5872 > "hash": "6fc80dcc62179dbc12fc0b5881275898f93444833d21b89dfe5f7fbcbb1d0d62"
@@ -63,15 +77,24 @@ is a JSON object with the following fields:
6377* `inputSrcs`:
6478 A list of store paths on which this derivation depends.
6579
80+ > **Example**
81+ >
82+ > ```json
83+ > "inputSrcs": [
84+ > "47y241wqdhac3jm5l7nv0x4975mb1975-separate-debug-info.sh",
85+ > "56d0w71pjj9bdr363ym3wj1zkwyqq97j-fix-pop-var-context-error.patch"
86+ > ]
87+ > ```
88+
6689* `inputDrvs`:
6790 A JSON object specifying the derivations on which this derivation depends, and what outputs of those derivations.
6891
6992 > **Example**
7093 >
7194 > ```json
7295 > "inputDrvs": {
73- > "/nix/store/ 6lkh5yi7nlb7l6dr8fljlli5zfd9hq58-curl-7.73.0.drv": ["dev"],
74- > "/nix/store/ fn3kgnfzl5dzym26j8g907gq3kbm8bfh-unzip-6.0.drv": ["out"]
96+ > "6lkh5yi7nlb7l6dr8fljlli5zfd9hq58-curl-7.73.0.drv": ["dev"],
97+ > "fn3kgnfzl5dzym26j8g907gq3kbm8bfh-unzip-6.0.drv": ["out"]
7598 > }
7699 > ```
77100
0 commit comments