项目作者: mugoh

项目描述 :
A multi-audio :musical_note: converter CLI that makes some bitful use of ffmeg in media format conversion
高级语言: Python
项目地址: git://github.com/mugoh/audioConvertor.git
创建时间: 2019-02-16T16:47:59Z
项目社区:https://github.com/mugoh/audioConvertor

开源协议:Apache License 2.0

下载


audioConvertor Build Status Coverage Status

audioConvertor is a multifile media format convertor command line tool. It allows conversion of files to various media types, the most emphasised on, being from video to audio.
The tool is a guide detailed out on @mugoh.ks/python-click-building-your-first-command-line-interface-application-6947d5319ef7">this blog post

Setup

  1. Access a cloned copy of the repo
    ```shell
    $ git clone https://github.com/hogum/audioConvertor
  1. 2. Change to the repo directory
  2. ```shell
  3. $ cd audioConvertor
  1. Optionally install ffmpeg. You can skip this step.

    Running the application for the first time will prompt for the installation.

    1. $ apt-get install ffmpeg

Dependecies

  1. Ensure to have pipenv installed
    1. $ apt install pipenv
  2. Install the project dependencies by running
    1. $ pipenv install
  • Alternatively, you can use a virtual environment with dependencies present by running
    1. $ pipenv shell

Interacting with the application

Basic Usage

The usage options are accesible on the help menu. This can be displayed by running:

  1. $ python convertor/cli.py --help
  1. Convert a video file to audio.
  • Required Options

    • --input_file -i Path to video file
  1. ```shell
  2. $ python convertor/cli.py -i /path/to/video/file/ -o /save/path/
  3. ```
  1. Convert mulitple video files from multiple directories

    1. $ python convert -i /path/to/root/directory/ -o /path/to/save/output/ --recursive

Testing

  1. Spawn a virtual environment
  1. $ pipenv shell
  1. Run tests
    1. $ pytest