Skip to content

Instantly share code, notes, and snippets.

@michaelskyba
Last active February 12, 2023 02:33
Show Gist options
  • Save michaelskyba/697a06b1f53f3f8a14e94bd9ccf4de3e to your computer and use it in GitHub Desktop.
Save michaelskyba/697a06b1f53f3f8a14e94bd9ccf4de3e to your computer and use it in GitHub Desktop.
--- old
+++ new
@@ -35,7 +35,7 @@
0) echo 'No more tracks in queue. Please refresh the database, or set $MSK_MUSIC_REFRESH.' && exit 1 ;;
# No tracks, but user wants automatic refreshing
- 1) find "$MUSIC_DIR" -type f | shuf > "$XDG_DATA_HOME/msk_music/tracks" ;;
+ 1) find "$MUSIC_DIR" -type f -name "*.mp4" | shuf > "$XDG_DATA_HOME/msk_music/tracks" ;;
esac
fi
@michaelskyba
Copy link
Author

michaelskyba commented Sep 26, 2021

2021-09-26: I have improved the original script. However, this patch will no longer be able to be applied directly, with the line numbers and everything being thrown off. Hopefully you can still see the idea behind it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment