View Source MixDependencySubmission.Dependency behaviour (mix_dependency_submission v1.0.0-beta.1)

Behaviour for implementing dependency details for custom Mix.SCM implementations.

usage

Usage

To define the SCM in a way so that it is recognized by this library, define a module called MixDependencySubmission.Dependency.[SCM Module Name] and it will be automatically be picked up.

Link to this section Summary

Link to this section Callbacks

Link to this callback

mix_dependency_to_package_url(dep)

View Source
@callback mix_dependency_to_package_url(dep :: Mix.Dep.t()) :: {:ok, Purl.t()} | :error

Link to this section Functions

Link to this function

resolve_version(dep, lock_callback \\ fn _lock -> :error end)

View Source
@spec resolve_version(
  dep :: Mix.Dep.t(),
  lock_callback :: (list() -> {:ok, Purl.version()} | :error)
) :: {:ok, Purl.version()} | :error