顯示具有 mp3 標籤的文章。 顯示所有文章
顯示具有 mp3 標籤的文章。 顯示所有文章

2010年1月26日 星期二

Split MP3 in CLI on Arch Linux

1. install mp3splt, utility for mp3/ogg splitting without decoding

sudo pacman -S mp3splt

2. usage

mp3splt input_file begin_time end_time -o output_file

time format: minutes.seconds[.hundredths]

2009年11月8日 星期日

Convert FLAC to MP3 on Arch Linux

1. install necessary packages to decode and encode

sudo pacman -S lame flac

2. pipe the decoded standart output for the encoder

flac -dc input.flac | lame -h - output.mp3

-d decode
-c write output to stdout

-h use some quality improvements

2007年7月14日 星期六

Set an alarm at a specified time on CentOS


at 23:00 2005-09-15
at> /usr/local/bin/alarm
at> ..
at> # multiple commands can be executed at same time
at> ..
at> <EOT> # pressing CTRL + D means save and exit


atq #lists the user's pending jobs

2007年7月11日 星期三

Set up an mp3 alarm on CentOS

1. Make sure the user who will run the alarm is not in /etc/cron.deny
2. Log in as the user then type crontab -e for editing his cron entry
# dom = Day of Month
# dow = Day of Week
# m h dom mon dow command
42 07 * * 1-5 /usr/local/bin/alarm

3. vi /usr/local/bin/alarm


# run xterm to execute mplayer in another window
# with the parameter, display 0 you can quit playing easily,
# the parameter -loop 0 means repeat forever.
/usr/bin/xterm -display :0 -bg black -fg white \
-e /usr/local/mplayer -loop 0 filename.mp3



/usr/bin/mplayer -loop 0 filename.mp3

4. Remember to give permission of execution to alarm
chmod 7xx alarm

5. An easy way to stop playing, use the command pkill

pkill mplayer