shoehorn v0.5.0 Shoehorn View Source

Link to this section Summary

Functions

Called after assembling the release

Called when the user invokes the mix release.clean task

Called after packaging the release

Called before assembling the release

Called before packaging the release

Called when an application is started

Link to this section Functions

Link to this function

after_assembly(release, opts) View Source

Called after assembling the release.

Should return a modified %Release{} or nil.

Callback implementation for Mix.Releases.Plugin.after_assembly/2.

Link to this function

after_cleanup(release, arg2) View Source

Called when the user invokes the mix release.clean task.

The callback will be passed the command line arguments to mix release.clean. It should clean up the files the plugin created. The return value of this callback is ignored.

Callback implementation for Mix.Releases.Plugin.after_cleanup/2.

Link to this function

after_package(release, opts) View Source

Called after packaging the release.

Should return a modified %Release{} or nil.

When in dev_mode, the packaging phase is skipped.

Callback implementation for Mix.Releases.Plugin.after_package/2.

Link to this function

before_assembly(release) View Source

Link to this function

before_assembly(release, opts) View Source

Called before assembling the release.

Should return a modified %Release{} or nil.

Callback implementation for Mix.Releases.Plugin.before_assembly/2.

Link to this function

before_package(release, opts) View Source

Called before packaging the release.

Should return a modified %Release{} or nil.

When in dev_mode, the packaging phase is skipped.

Callback implementation for Mix.Releases.Plugin.before_package/2.

Link to this function

generate_boot_script(app_release) View Source

Called when an application is started.

This function is called when an application is started using Application.start/2 (and functions on top of that, such as Application.ensure_started/2). This function should start the top-level process of the application (which should be the top supervisor of the application's supervision tree if the application follows the OTP design principles around supervision).

start_type defines how the application is started:

  • :normal - used if the startup is a normal startup or if the application is distributed and is started on the current node because of a failover from another node and the application specification key :start_phases is :undefined.
  • {:takeover, node} - used if the application is distributed and is started on the current node because of a failover on the node node.
  • {:failover, node} - used if the application is distributed and is started on the current node because of a failover on node node, and the application specification key :start_phases is not :undefined.

start_args are the arguments passed to the application in the :mod specification key (e.g., mod: {MyApp, [:my_args]}).

This function should either return {:ok, pid} or {:ok, pid, state} if startup is successful. pid should be the PID of the top supervisor. state can be an arbitrary term, and if omitted will default to []; if the application is later stopped, state is passed to the stop/1 callback (see the documentation for the c:stop/1 callback for more information).

use Application provides no default implementation for the start/2 callback.

Callback implementation for Application.start/2.