Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Makefile #45

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
.PHONY: install

input_conf="g script-message contact-sheet-close; script-message playlist-view-toggle\nc script-message playlist-view-close; script-message contact-sheet-toggle"

install:
mkdir -p ${HOME}/.config/mpv/scripts \
${HOME}/.config/mpv/script-modules \
${HOME}/.config/mpv/script-opts

# Copy scripts
install -m 0644 scripts/contact-sheet.lua \
scripts/gallery-thumbgen.lua \
scripts/playlist-view.lua \
${HOME}/.config/mpv/scripts/

# Copy script-opts
install -m 0644 script-opts/contact_sheet.conf \
script-opts/gallery_worker.conf \
script-opts/playlist_view.conf \
${HOME}/.config/mpv/script-opts/

# Copy script-modules
install -m 0644 script-modules/gallery.lua \
${HOME}/.config/mpv/script-modules/

# Add configuration to input.conf
# to toggle between contact and gallery since they can not
# be used at the same time
printf $(input_conf) >> ${HOME}/.config/mpv/input.conf

2 changes: 1 addition & 1 deletion scripts/gallery-thumbgen.lua
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ function ytdl_thumbnail_url(input_path)
local es, json, result = exec(command)

if (es < 0) or (json == nil) or (json == "") then
msg.error("fetching thumbnail url with youtube-dl failed for" .. input_path)
msg.error("fetching thumbnail url with youtube-dl failed for: " .. input_path)
return input_path
end
local json, err = utils.parse_json(json)
Expand Down