Bump latest version to 1.1
And make this version a pre-req for the env field in workspaces Signed-off-by: Rudi Grinberg <rudi.grinberg@gmail.com>
This commit is contained in:
parent
8cda4349fa
commit
61d33114ee
|
@ -5,6 +5,11 @@ open Stanza.Of_sexp
|
||||||
for simplicity *)
|
for simplicity *)
|
||||||
let syntax = Stanza.syntax
|
let syntax = Stanza.syntax
|
||||||
|
|
||||||
|
let env_field =
|
||||||
|
field_o "env"
|
||||||
|
(Syntax.since syntax (1, 1) >>= fun () ->
|
||||||
|
Dune_env.Stanza.t)
|
||||||
|
|
||||||
module Context = struct
|
module Context = struct
|
||||||
module Target = struct
|
module Target = struct
|
||||||
type t =
|
type t =
|
||||||
|
@ -49,7 +54,7 @@ module Context = struct
|
||||||
}
|
}
|
||||||
|
|
||||||
let t ~profile =
|
let t ~profile =
|
||||||
field_o "env" Dune_env.Stanza.t >>= fun env ->
|
env_field >>= fun env ->
|
||||||
field "targets" (list Target.t) ~default:[Target.Native]
|
field "targets" (list Target.t) ~default:[Target.Native]
|
||||||
>>= fun targets ->
|
>>= fun targets ->
|
||||||
field "profile" string ~default:profile
|
field "profile" string ~default:profile
|
||||||
|
@ -155,7 +160,7 @@ include Versioned_file.Make(struct type t = unit end)
|
||||||
let () = Lang.register syntax ()
|
let () = Lang.register syntax ()
|
||||||
|
|
||||||
let t ?x ?profile:cmdline_profile () =
|
let t ?x ?profile:cmdline_profile () =
|
||||||
field_o "env" Dune_env.Stanza.t >>= fun env ->
|
env_field >>= fun env ->
|
||||||
field "profile" string ~default:Config.default_build_profile
|
field "profile" string ~default:Config.default_build_profile
|
||||||
>>= fun profile ->
|
>>= fun profile ->
|
||||||
let profile = Option.value cmdline_profile ~default:profile in
|
let profile = Option.value cmdline_profile ~default:profile in
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
(lang dune 1.0)
|
(lang dune 1.1)
|
|
@ -1,4 +1,4 @@
|
||||||
(lang dune 1.0)
|
(lang dune 1.1)
|
||||||
|
|
||||||
(env
|
(env
|
||||||
(default
|
(default
|
||||||
|
|
Loading…
Reference in New Issue