This PR adds the `--setup` option to the `lean` CLI. It takes a path to a JSON file containing information about a module's imports and configuration, superseding that in the module's own file header. This will be used by Lake to specify paths to module artifacts (e.g., oleans and ileans) separate from the `LEAN_PATH` schema. To facilitate JSON serialization of the header data structure, `NameMap` JSON instances have been added to core, and `LeanOptions` now makes use of them.
6 lines
164 B
Bash
Executable file
6 lines
164 B
Bash
Executable file
#!/usr/bin/env bash
|
|
set -euo pipefail
|
|
|
|
# Test that Lean will use the specified olean from `setup.json`
|
|
lean Dep.lean -o Dep.olean
|
|
lean Test.lean --setup setup.json
|