Find the answer to your Linux question:
Results 1 to 3 of 3
I have a .wav file in a directory, I need to write a small linux shell script which picks and plays that file, so far I have no clue how ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    May 2005
    Posts
    3

    How to play wav file with linux shell script


    I have a .wav file in a directory, I need to write a small linux shell script which picks and plays that file, so far I have no clue how to play wav files, any help is greatly

  2. #2
    Linux Guru lakerdonald's Avatar
    Join Date
    Jun 2004
    Location
    St. Petersburg, FL
    Posts
    5,035
    Code:
    #!/bin/bash
    amp $1
    replacing amp with your favorite media player. then name it say "wavplay" and do this:
    Code:
    chmod +x wavplay
    ./wavplay file.wav

  3. #3
    Linux Engineer
    Join Date
    Mar 2005
    Posts
    1,431
    You can make "play" play the file, or "artsplay" under KDE or perhaps another media player like mplayer without gui.

  4. $spacer_open
    $spacer_close

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •