├── .github └── workflows │ └── installation.yml ├── install └── README.md /.github/workflows/installation.yml: -------------------------------------------------------------------------------- 1 | name: FFmpeg Installation 2 | 3 | on: 4 | push: 5 | branches: [ "master" ] 6 | pull_request: 7 | branches: [ "master" ] 8 | 9 | jobs: 10 | build: 11 | runs-on: ubuntu-latest 12 | 13 | steps: 14 | - name: Install the ffmpeg 15 | run: | 16 | curl https://raw.githubusercontent.com/XniceCraft/ffmpeg-colab/master/install -o install 17 | chmod +x ./install 18 | ./install 19 | 20 | - name: Test 21 | run: | 22 | wget http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ForBiggerBlazes.mp4 23 | ffmpeg -i ForBiggerBlazes.mp4 -c:a libfdk_aac -b:a 192k -c:v libopenh264 -b:v 1000k hi.mp4 24 | -------------------------------------------------------------------------------- /install: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | set -e -u 4 | 5 | FFMPEGLOC=$(which ffmpeg) 6 | CURL_EXISTS=$(command -v "curl") 7 | WGET_EXISTS=$(command -v "wget") 8 | if [ -z $CURL_EXISTS ] && [ -z $WGET_EXISTS ]; then 9 | echo "Please install either wget or curl" 10 | exit 1 11 | fi 12 | 13 | if [ -z "$FFMPEGLOC" ]; then 14 | echo "No FFmpeg found" 15 | else 16 | echo "FFmpeg was found at "$FFMPEGLOC 17 | echo "Removing old FFmpeg" 18 | rm -rf $FFMPEGLOC 19 | echo "Done" 20 | fi 21 | 22 | if [ ! -f "ffmpeg" ]; then 23 | if [ $WGET_EXISTS ]; then 24 | wget "https://github.com/XniceCraft/ffmpeg-colab/releases/download/7.1/ffmpeg" -O ffmpeg 25 | elif [ $CURL_EXISTS ]; then 26 | curl -o ffmpeg "https://github.com/XniceCraft/ffmpeg-colab/releases/download/7.1/ffmpeg" 27 | fi 28 | fi 29 | 30 | if [ -f "ffmpeg" ]; then 31 | echo "Moving new ffmpeg to /usr/bin" 32 | chmod +x ffmpeg 33 | if [ $(mv ffmpeg "/usr/bin/"; echo $?) != 0 ]; then 34 | echo "Failed move ffmpeg to /usr/bin" 35 | echo "Moving new ffmpeg to /usr/local/bin" 36 | if [ $(mv ffmpeg "/usr/local/bin/"; echo $?) != 0 ]; then 37 | echo "Installation failed. Please check your permission" 38 | exit 1 39 | fi 40 | fi 41 | echo "FFmpeg was successfully installed" 42 | fi 43 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # FFmpeg 7.1 2 |