This script is designed to convert your media to a universal mp4 format with support for automation when combined with NZBGet/SABnzbd and many options to customize. Avoid transcoding and support native playback across all devices with Plex. What does it do exactly? It converts your media to a universal format. Why? Plex! Plex transcodes anything a client cannot direct play normally but transcoding is a CPU intensive task and if your CPU falls short, soon after the client will begin to buffer. By using this script you will eliminate transcoding or at least cut down on it. Fully integrates with NZBGet so that media converts on post-process! SABnzbd is also supported although it does not get a WebUI config. Got a bug report? Create an issue here! Tested using Ubuntu Server 16.04 LTS, Debian 8.6.0, Linux Mint 18.1, Fedora Server 25, CentOS 7 and macOS Sierra Download/Installing: Debian: You must install git before you can download M4V-Converter. First off check to see if the command sudo is available. You can do so by opening a terminal and typing it in. If you receive this response "-bash: sudo: command not found" then you must of setup a root password during installation and as such do not have a sudo command. Therefore, you will need to use the su command instead. This will require you to enter the root password and will log you in AS root. WITH SUDO: Code: sudo apt -y install git WITHOUT SUDO: Code: su apt -y install git exit Linux Mint: You must install git before you can download M4V-Converter. You can do so by running this command: Code: sudo apt -y install git Fedora: You must install git before you can download M4V-Converter. You can do so by running this command: Code: sudo dnf -y install git CentOS: You must install git before you can download M4V-Converter. You can do so by running this command: Code: sudo yum -y install git macOS: Homebrew is required, you can install it from here. You must install git before you can download M4V-Converter. You can so by running this command: Code: brew install git Open a terminal and run the following command: Code: git clone https://github.com/Digiex/M4V-Converter.git Dependencies: This script requires ffmpeg, ffprobe and bash 4. All supported Linux distributions already have Bash 4. You can run the provided script to automatically install ffmpeg and ffprobe: Code: cd M4V-Converter sudo ./install_ffmpeg.sh Debian: First off check to see if the command sudo is available. You can do so by opening a terminal and typing it in. If you receive this response "-bash: sudo: command not found" then you must of setup a root password during installation and as such do not have a sudo command. Therefore, we will need to use the su command instead. This will require you to enter the root password and will log you in AS root. WITH SUDO: Code: sudo ./install_ffmpeg.sh WITHOUT SUDO: Code: su ./install_ffmpeg.sh exit macOS: You can install Bash 4 with Homebrew by running this command: Code: brew install bash When installing ffmpeg and ffprobe using the above command you will NOT need root. Remove the sudo prefix or simply use this: Code: ./install_ffmpeg.sh Updating: Open a terminal and run the following commands: Code: cd M4V-Converter git pull This will pull any changes directly from Github. If you use NZBGet/SABnzbd I would also recommend restarting those services. Usage: Open a terminal and run the following commands: Code: cd M4V-Converter ./M4V-Converter.sh The above command will provide additional help in order to properly use this. NZBGet/SABnzbd: Below is what you will need to do in order to get this script functioning with NZBGet/SABnzbd. Now you will need to know where your scripts folder is. There is not much I can do to help you here, by default SABnzbd does not specify a default scripts folder location. NZBGet does but this will vary based on your Operating System. Code: ln -s M4V-Converter/M4V-Converter.sh YOUR_SCRIPTS_FOLDER_DIRECTORY/M4V-Converter.sh Replace YOUR_SCRIPTS_FOLDER_DIRECTORY with the location of your scripts folder. This will look something like /Users/xzkingzxburnzx/Library/Application\ Support/NZBGet/Scripts If you choose to you can just copy/paste M4V-Converter.sh into your Scripts folder but by doing this you will not be able to update (see Updating section) with ease. Instead you will need to manually copy/paste with every update. NZBGet: Open the WebUI for NZBGet typically located at http://localhost:6789/. Now you can decide which way to want to enable the M4V-Converter. (Recommended) If you have setup a Movies or TV Shows/Series category then go into Settings and then Categories, now under Category#.PostScript choose to enable M4V-Converter.sh If you have not setup categories yet or simply do not want to then you can just enable it as a default script. Go into Settings and then Extension Scripts, for PostScript enable M4V-Converter.sh. Now you can into Settings and then M4V-Converter. From here you can customize how you would like the M4V-Converter to function. (see config section) You DO NOT need to create a config file, as the WebUI is providing that for you. SABnzbd: Open the WebUI for NZBGet typically located at http://localhost:8080/. if you have setup a Movies or TV Shows/Series category then go into SABnzbd Config and then Categories, now under Script choose M4V-Converter.sh. Unfortunately, SABnzbd does not integrate as well as NZBGet does when it comes to scripts so you won't be able to use the WebUI to edit the M4V-Converter settings. At this point though you can now create a M4V-Converter.conf file, using the default.conf and edit the settings to your liking. (see config section) You should also enable the "User script can flag job as failed" option. This will allow M4V-Converter to mark the job as failed should anything go wrong, can also help to prevent fakes. Configuration: To get a better idea of the settings you can edit, have a look at them here. Now you need to create a config file based off the default file. Code: cd M4V-Converter cp default.conf M4V-Converter.conf You can now edit the M4V-Converter.conf file to your liking. DO NOT edit the default.conf If you need help with anything, just ask below.
Hey there! I apologize in advance if I'm missing something obvious here -- I'm a Linux noob that learns something new every day. I downloaded/installed everything as (I think) directed. I'm using SABnzbd and when the script runs, I get this error in SABnzbd: .../M4V-Converter.sh: line 299: ((: == 0 : syntax error: operand expected (error token is "== 0 "). Any ideas? I'm on Ubuntu Server 16.04. Thanks!