~mika/www.m1kadev.nl

ref: 6f77896612eb67d663362b5a218766f25b0108ca www.m1kadev.nl/kethel/lib/filex.ex -rw-r--r-- 227 bytes
6f778966 — m1kadev update colophon, remove pastes from index 6 months ago
                                                                                
1
2
3
4
5
6
7
8
9
defmodule FileX do
  @typedoc "Any path"
  @type path() :: binary()

  @spec trimmed_filename(path()) :: binary()
  def trimmed_filename(path) do
    Path.basename(path) |> Path.rootname() |> String.replace("-", "_")
  end
end