[opam-devel] shared directory

Anil Madhavapeddy anil at recoil.org
Thu Nov 21 01:25:19 GMT 2013

On 21 Nov 2013, at 00:59, Sean McLaughlin <seanmcl at gmail.com> wrote:

> I'm installing elisp files.  What would you tell the user to put in their .emacs?  
> This is Louis' proposal:
> (setq path-to-opam-shared 
>   (replace-regexp-in-string "\n" "" (shell-command-to-string "opam config var share")))
> It would be nicer to do 
> (setq path-to-opam-shared "~/.opam/current/shared")

If both of them work, does the specific details of the elisp file matter? The first version will work with a non-standard OPAMROOT (which a distribution might choose to alter, for instance for NFS sharing).

> What is opam exec?
> $ opam --version
> 1.1.0
> $ opam exec
> opam: unknown command `exec'
> Usage: opam COMMAND ...
> Try `opam --help' for more information.

Sorry, `opam config exec`:

  Execute the shell script given in parameter with the correct environment variables. This option
  can be used to cross-compile between switches using opam config exec "CMD ARG1 ... ARGn"

This is very useful in scripted builds.


More information about the opam-devel mailing list