Skip to content

Instantly share code, notes, and snippets.

@bboa

bboa/rec.desktop Secret

Last active August 16, 2016 18:38
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 bboa/c76dd8e5c7fe9b52390a7eb267608544 to your computer and use it in GitHub Desktop.
Save bboa/c76dd8e5c7fe9b52390a7eb267608544 to your computer and use it in GitHub Desktop.
AudioNote .desktop file
[Desktop Entry]
Exec=sh -c "DIR=`xdg-user-dir MUSIC`; if [ -z $DIR ]; then DIR=~/AudioNotes; else DIR=\"$DIR/AudioNotes\"; fi; NOW=`date +%%F_%%T`; if pgrep arecord; then pkill arecord; notify-send -i media-record Аудиозаметка 'Запись завершена'; sleep 2 && pkill notify-osd & exit; fi; [ ! -d \"$DIR\" ] && mkdir -p \"$DIR\"; amixer -c 0 set 'Mic Boost',0 3; arecord -f dat -d 600 -D hw:0,0 | lame --preset voice - \"$DIR/$NOW.mp3\" & notify-send -i media-record Аудиозаметка $NOW; sleep 2 && pkill notify-osd &"
Type=Application
Name[ru]=Аудиозаметка
Name=AudioNote
Icon=media-record
Categories=AudioVideo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment