fluminus v1.3.3 Fluminus.Util View Source

A collection of common methods in Fluminus.

Link to this section Summary

Functions

Downloads the given url to a destination path generated by the provided function.

Sanitises filename according to Unix standard.

Link to this section Functions

Link to this function

download(f, destination, verbose)

View Source
download((() -> {:ok, String.t()} | {:error, any()}), Path.t(), bool()) ::
  :ok | {:error, :exists | any()}

Downloads the given url to a destination path generated by the provided function.

This function will return {:error, :exists} if the file already exists.

Link to this function

sanitise_filename(name)

View Source
sanitise_filename(String.t()) :: String.t()

Sanitises filename according to Unix standard.