Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: Luke Yelavich <themuso@ubuntu.com>
Cc: alsa-devel@alsa-project.org
Subject: Re: [PATCH] alsa-info.sh: add command-line flag to print	alsa info to stdout
Date: Thu, 23 Apr 2009 12:19:18 +0200	[thread overview]
Message-ID: <s5heivj8yft.wl%tiwai@suse.de> (raw)
In-Reply-To: <1240480834-16528-1-git-send-email-themuso@ubuntu.com>

At Thu, 23 Apr 2009 20:00:33 +1000,
Luke Yelavich wrote:
> 
> Add the --stdout command-line flag to allow displaying the collected alsa
> information directly to standard output. This is useful for bug information
> collecting systems, such as Ubuntu's apport.
> 
> Signed-off-by: Luke Yelavich <themuso@ubuntu.com>

Looks good.  Applied both patches now.

Thanks!

Takashi


> ---
>  utils/alsa-info.sh |   34 +++++++++++++++++++++++++++++-----
>  1 files changed, 29 insertions(+), 5 deletions(-)
> 
> diff --git a/utils/alsa-info.sh b/utils/alsa-info.sh
> index 0fff671..ee0de16 100755
> --- a/utils/alsa-info.sh
> +++ b/utils/alsa-info.sh
> @@ -277,6 +277,12 @@ case "$1" in
>  		REPEAT=""
>  		shift
>  		;;
> +	--stdout)
> +		DIALOG=""
> +		NOUPLOAD="yes"
> +		QUESTION="no"
> +		TOSTDOUT="yes"
> +		;;
>  esac
>  done
>  		
> @@ -627,6 +633,17 @@ then
>  				fi
>  			fi
>  			;;
> +		--stdout)
> +			NOUPLOAD="yes"
> +			withdevices
> +			withconfigs
> +			withaplay
> +			withamixer
> +			withalsactl
> +			withlsmod
> +			cat $FILE
> +			rm $FILE
> +			;;
>  		--about)
>  			echo "Written/Tested by the following users of #alsa on irc.freenode.net:"
>  			echo ""
> @@ -635,6 +652,7 @@ then
>  			echo "	gnubien - Various script ideas / Testing"
>  			echo "	GrueMaster - HDA Intel specific items / Testing"
>  			echo "	olegfink - Script update function"
> +			echo "  TheMuso - display to stdout functionality"
>  			exit 0
>  			;;
>  		*)
> @@ -652,6 +670,8 @@ then
>  			echo "	--no-upload (do not upload contents to remote server)"
>  			echo "	--pastebin (use http://pastebin.ca) as remote server"
>  			echo "	    instead www.alsa-project.org"
> +			echo "  --stdout (print alsa information to standard output"
> +			echo "      instead of a file)"
>  			echo "	--about (show some information about the script)"
>  			echo "	--debug (will run the script as normal, but will not"
>  			echo "	     delete $FILE)"
> @@ -668,7 +688,9 @@ fi
>  
>  if [ -n "$NOUPLOAD" ]; then
>  
> -	mv $FILE $NFILE || exit 1
> +	if [ -z "$TOSTDOUT" ]; then
> +		mv $FILE $NFILE || exit 1
> +	fi
>  
>  	if [[ -n $DIALOG ]]
>  	then
> @@ -686,10 +708,12 @@ if [ -n "$NOUPLOAD" ]; then
>  			echo "Your ALSA information can be seen by looking in $NFILE"
>  			echo ""
>  		else
> -			echo "You requested that your information was NOT automatically uploaded to the $WWWSERVICE"
> -			echo ""
> -			echo "Your ALSA information can be seen by looking in $NFILE"
> -			echo ""
> +			if [ -z "$TOSTDOUT" ]; then
> +				echo "You requested that your information was NOT automatically uploaded to the $WWWSERVICE"
> +				echo ""
> +				echo "Your ALSA information can be seen by looking in $NFILE"
> +				echo ""
> +			fi
>  		fi
>  	fi
>  
> -- 
> 1.6.0.4
> 
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
> 

  parent reply	other threads:[~2009-04-23 10:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-04-23 10:00 [PATCH] alsa-info.sh: add command-line flag to print alsa info to stdout Luke Yelavich
2009-04-23 10:00 ` [PATCH] alsa-info.sh: use distros package manager to retrieve alsa library version Luke Yelavich
2009-04-23 10:19 ` Takashi Iwai [this message]
  -- strict thread matches above, loose matches on Subject: below --
2009-03-30  0:03 [PATCH] alsa-info.sh: add command-line flag to print alsa info to stdout Luke Yelavich

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=s5heivj8yft.wl%tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=alsa-devel@alsa-project.org \
    --cc=themuso@ubuntu.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox