ocaml
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Work around a shadowing issue caused by a new version of cmdliner

+13 -12
+13 -12
bin/forester/main.ml
··· 153 153 let doc = "A TOML file like $(i,forest.toml)" in 154 154 Arg.(value & pos 0 file "forest.toml" & info [] ~docv:"FOREST" ~doc) 155 155 156 - let build_cmd ~env = 156 + let build_cmd ~env:env_ = 157 157 let arg_dev = 158 158 let doc = 159 159 "Run forester in development mode; this will attach source file \ ··· 180 180 in 181 181 let info = Cmd.info "build" ~version ~doc ~man in 182 182 Cmd.v info 183 - Term.(const (build ~env) $ arg_logs $ arg_config $ arg_dev $ arg_no_theme) 183 + Term.( 184 + const (build ~env:env_) $ arg_logs $ arg_config $ arg_dev $ arg_no_theme) 184 185 185 - let new_tree_cmd ~env = 186 + let new_tree_cmd ~env:env_ = 186 187 let arg_prefix = 187 188 let doc = "The namespace prefix for the created tree." in 188 189 Arg.value ··· 212 213 let info = Cmd.info "new" ~version ~doc in 213 214 Cmd.v info 214 215 Term.( 215 - const (new_tree ~env) 216 + const (new_tree ~env:env_) 216 217 $ arg_config $ arg_dest_dir $ arg_prefix $ arg_template $ arg_random) 217 218 218 - let complete_cmd ~env = 219 + let complete_cmd ~env:env_ = 219 220 let arg_title = 220 221 let doc = "The tree title prefix to complete." in 221 222 Arg.value @@ Arg.opt Arg.string "" @@ Arg.info ["title"] ~docv:"title" ~doc 222 223 in 223 224 let doc = "Complete a tree title." in 224 225 let info = Cmd.info "complete" ~version ~doc in 225 - Cmd.v info Term.(const (complete ~env) $ arg_config $ arg_title) 226 + Cmd.v info Term.(const (complete ~env:env_) $ arg_config $ arg_title) 226 227 227 - let query_all_cmd ~env = 228 + let query_all_cmd ~env:env_ = 228 229 let doc = "List all trees in JSON format" in 229 230 let info = Cmd.info "all" ~version ~doc in 230 - Cmd.v info Term.(const (query_all ~env) $ arg_config) 231 + Cmd.v info Term.(const (query_all ~env:env_) $ arg_config) 231 232 232 233 let query_cmd ~env = 233 234 let doc = "Query your forest" in 234 235 let info = Cmd.info "query" ~version ~doc in 235 236 Cmd.group info [query_all_cmd ~env] 236 237 237 - let init_cmd ~env = 238 + let init_cmd ~env:env_ = 238 239 let arg_dir = 239 240 let doc = "The directory in which to initialize the forest" in 240 241 Arg.value ··· 253 254 ] 254 255 in 255 256 let info = Cmd.info "init" ~version ~doc ~man in 256 - Cmd.v info Term.(const (init ~env) $ arg_dir) 257 + Cmd.v info Term.(const (init ~env:env_) $ arg_dir) 257 258 258 259 let lsp ~env _ config = 259 260 let config = Config_parser.parse_forest_config_file config in 260 261 Forester_lsp.start ~env ~config 261 262 262 - let lsp_cmd ~env = 263 + let lsp_cmd ~env:env_ = 263 264 let man = 264 265 [ 265 266 `S Manpage.s_description; ··· 268 269 in 269 270 let doc = "Start the LSP" in 270 271 let info = Cmd.info "lsp" ~version ~doc ~man in 271 - Cmd.v info Term.(const (lsp ~env) $ arg_logs $ arg_config) 272 + Cmd.v info Term.(const (lsp ~env:env_) $ arg_logs $ arg_config) 272 273 273 274 let cmd ~env = 274 275 let doc = "a tool for tending mathematical forests" in