diff --git a/Dockerfile b/Dockerfile index 9c93dc8..e987099 100644 --- a/Dockerfile +++ b/Dockerfile @@ -29,5 +29,7 @@ RUN chmod +x ./docker-run.sh # Install Elixir deps RUN mix deps.get +# Gives us iex shell history +ENV ERL_AFLAGS="-kernel shell_history enabled" EXPOSE 4008 diff --git a/lib/pinchflat/media_client/backends/yt_dlp/command_runner.ex b/lib/pinchflat/media_client/backends/yt_dlp/command_runner.ex index f803b02..9f24390 100644 --- a/lib/pinchflat/media_client/backends/yt_dlp/command_runner.ex +++ b/lib/pinchflat/media_client/backends/yt_dlp/command_runner.ex @@ -13,9 +13,9 @@ defmodule Pinchflat.MediaClient.Backends.YtDlp.CommandRunner do Returns {:ok, binary()} | {:error, output, status}. - # IDEA: deduplicate command opts, keeping the last one on conflict - although possibly not needed (and a LOT easier) if yt-dlp - just ignores duplicate options (ie: look into that) + IDEA: Indexing takes a long time, but the output is actually streamed to stdout. + Maybe we could listen to that stream instead so we can index videos as they're discovered. + See: https://stackoverflow.com/a/49061086/5665799 """ @impl BackendCommandRunner def run(url, command_opts) do