osd-sound 501 B

123456789101112131415161718192021
  1. #!/bin/sh
  2. case "$1" in
  3. -h | --help)
  4. echo 'Usage: osd-sound [AMIXER-ARGS...]
  5. Run "amixer AMIXER-ARGS..." and display sound value in OSD.
  6. Without arguments, show previously displayed sound value.'
  7. exit 0 ;;
  8. *)
  9. if [[ -z "$@" ]]; then
  10. gdpipe "(osd-sound)"
  11. else
  12. quoted_args=
  13. for arg; do
  14. quoted_args="$quoted_args \"$arg\""
  15. done
  16. gdpipe "(osd-sound $quoted_args)"
  17. fi
  18. ;;
  19. esac