Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #240507

Re: Persistent names for audio devices.

From Tixy <tixy@yxit.co.uk>
Newsgroups linux.debian.user
Subject Re: Persistent names for audio devices.
Date 2021-09-28 21:20 +0200
Message-ID <D2qNX-Ka-1@gated-at.bofh.it> (permalink)
References (5 earlier) <CGDId-6o7-1@gated-at.bofh.it> <CH1rb-3Fb-1@gated-at.bofh.it> <D2nGp-79Q-11@gated-at.bofh.it> <D2pfb-8aR-1@gated-at.bofh.it> <D2pyy-8hq-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


I've reordered this reply to get rid of top posting...

On Tue, 2021-09-28 at 17:38 +0000, Nils wrote:
> Am 28. September 2021 19:32:02 MESZ schrieb Greg Wooledge <
> greg@wooledge.org>:
> > On Tue, Sep 28, 2021 at 08:19:26AM -0700, peter@easthope.ca wrote:
> > > > CONCLUSIONS
> > > > 
> > > > Audio messages can be interpreted.  Eg.,
> > > > set AUDIODEV=plughw:CARD=ICH5,DEV=0; play m94.WAV
> > > 
> > > Hasty reply.  In further use, didn't always work.  I removed the PCI 
> > > sound card, removed the plastic cover from the sockets on the system 
> > > board and connected speakers.  Subsequently commands such as this 
> > > always work.
> > > 
> > > set AUDIODEV=plughw:CARD=ICH5,DEV=0 ; play a42.WAV
> > 
> > Are you in csh/tcsh?  If you're in a more "normal" shell (bash or zsh),
> > that set command doesn't do anything useful.  Certainly nothing that
> > would affect the play command.
> > 
> > Even if you're in (t)csh, my understanding is that "set" sets shell
> > variables, and you need "setenv" to set environment variables (which
> > could conceivably affect the play command).  So, even in (t)csh, I
> > don't see how your set command is supposed to work.
> > 
> > Other shells... rc? fish?  I don't know these.  I have no idea what
> > the set command does in them.
> > 
>
> I agree. In the "normal" shells, you need to use "export" instead of "set"!
>

Or, if you don't want to assign the variable value in the current shell
environment, just that of an external command you run, then you can
make the assignment part of the same command expression: 

  VAR=value command

Example in action...

$ FOO=foo
$ FOO=bar sh -c 'echo $FOO'
bar
# command above saw new value 'bar'
$ echo $FOO
foo
# this shell kept original value 'foo'

-- 
Tixy

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Re: Persistent names for audio devices. peter@easthope.ca - 2021-09-28 18:00 +0200
  Re: Persistent names for audio devices. ghe2001 <ghe2001@protonmail.com> - 2021-09-28 19:30 +0200
    Re: Persistent names for audio devices. peter@easthope.ca - 2021-09-28 23:40 +0200
      Re: Persistent names for audio devices. David Wright <deblis@lionunicorn.co.uk> - 2021-09-29 01:40 +0200
        Re: Persistent names for audio devices. peter@easthope.ca - 2021-09-29 22:40 +0200
          Re: Persistent names for audio devices. David Wright <deblis@lionunicorn.co.uk> - 2021-09-30 05:40 +0200
            Re: Persistent names for audio devices. peter@easthope.ca - 2021-09-30 19:10 +0200
  Re: Persistent names for audio devices. Greg Wooledge <greg@wooledge.org> - 2021-09-28 19:40 +0200
    Re: Persistent names for audio devices. Nils <tuxifan@posteo.de> - 2021-09-28 20:00 +0200
      Re: Persistent names for audio devices. Tixy <tixy@yxit.co.uk> - 2021-09-28 21:20 +0200
    Re: Persistent names for audio devices. peter@easthope.ca - 2021-09-29 00:10 +0200
      Re: Persistent names for audio devices. Greg Wooledge <greg@wooledge.org> - 2021-09-29 00:20 +0200
      Re: Persistent names for audio devices. <tomas@tuxteam.de> - 2021-09-29 09:00 +0200
        Re: Persistent names for audio devices. David <bouncingcats@gmail.com> - 2021-09-29 13:00 +0200

csiph-web