Mix v1.4.2 mix archive.install View Source
Installs an archive locally.
If no argument is supplied but there is an archive in the project’s
root directory (created with mix archive.build), then the archive
will be installed locally. For example:
mix do archive.build, archive.install
If an argument is provided, it should be a local path or a URL to a prebuilt archive, a git repository, a github repository, or a hex package.
mix archive.install archive.ez
mix archive.install path/to/archive.ez
mix archive.install https://example.com/my_archive.ez
mix archive.install git https://path/to/git/repo
mix archive.install git https://path/to/git/repo branch git_branch
mix archive.install git https://path/to/git/repo tag git_tag
mix archive.install git https://path/to/git/repo ref git_ref
mix archive.install github user/project
mix archive.install github user/project branch git_branch
mix archive.install github user/project tag git_tag
mix archive.install github user/project ref git_ref
mix archive.install hex hex_package
mix archive.install hex hex_package 1.2.3
After installation, the tasks in the archive are available locally:
mix some_task
Command line options
--sha512- checks the archive matches the given SHA-512 checksum--force- forces installation without a shell prompt; primarily intended for automation in build systems likemake--submodules- fetches repository submodules before building archive from git or github--app- specifies a custom app name to be used for building the archive from git, github, or hex
Link to this section Summary
Functions
For installs involving a fetch, this will be executed as the in_package
Checks that the install_spec and opts are supported by the respective module
Returns a list of already installed version of the same archive or escript
The installation itself
A task needs to implement run which receives
a list of command line args
Link to this section Functions
For installs involving a fetch, this will be executed as the in_package.
Callback implementation for c:Mix.Local.Installer.build/1.
Checks that the install_spec and opts are supported by the respective module.
Callback implementation for c:Mix.Local.Installer.check_install_spec/2.
Returns a list of already installed version of the same archive or escript.
Callback implementation for c:Mix.Local.Installer.find_previous_versions/2.
The installation itself.
Callback implementation for c:Mix.Local.Installer.install/3.
A task needs to implement run which receives
a list of command line args.
Callback implementation for Mix.Task.run/1.