diff --git a/bashrc.sh b/bashrc.sh index dd5ef5f..fc0a04f 100755 --- a/bashrc.sh +++ b/bashrc.sh @@ -375,6 +375,20 @@ function pull-plex { go-root cp -Rv "$plex_dir"/{1,2}/* "$dest" + + # TBD: Needs tested. + cd "$dest" + ls | while read dir; do + cd $dir + if [[ -e *.chunk0 ]]; then + final="movie.mkv" + echo "Catting files together to make '$final'." + ls -lh *.chunk* + cat *.chunk* > $final + ls -lh $final + fi + cd .. + done }