Skip to content

Instantly share code, notes, and snippets.

@DmitryMyadzelets
Last active May 14, 2019 10:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save DmitryMyadzelets/31a8e4db33b2c40cf5ed7a7615c268e6 to your computer and use it in GitHub Desktop.
Save DmitryMyadzelets/31a8e4db33b2c40cf5ed7a7615c268e6 to your computer and use it in GitHub Desktop.
Record audio stream in Linux

Record the current audio stream, and convert to mp3.

parec -d 0 | lame -r -V0 - out.mp3

Split the file based on silence in it. Source.

sox -V3 in.mp3 out_.mp3 silence -l 1 0.5 0.1% 1 2.0 0.1% : newfile : restart
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment