Skip to content
This repository has been archived by the owner on Aug 21, 2023. It is now read-only.

pulse2jack: Add the option to use a user-selected config file #308

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mead0w0
Copy link

@mead0w0 mead0w0 commented Feb 12, 2021

The pulse configuration file is selected from, in order:

  • An environment variable
    • CADENCE_PULSE2JACK_PLAY/CADENCE_PULSE2JACK_PLAYREC
  • A file
    • ~/.config/Cadence/pulse2jack/play[+rec].pa
  • The original default file
    • $INSTALL_PREFIX/share/cadence/pulse2jack/play[+rec].pa

I know there are a couple PRs for #234 that have stalled out and I thought this might be an easier most-of-the-way solution to get merged. I'm using it myself currently.

If anyone wants to test it out, you can put the cadence-pulse2jack file in e.g. ~/bin and prefix it to your $PATH in your bashrc, making sure to start cadence from the command line or somewhere else with the correct $PATH.

The pulse configuration file is selected from, in order:
- An environment variable
  - CADENCE_PULSE2JACK_PLAY/CADENCE_PULSE2JACK_PLAYREC
- A file
  - ~/.config/Cadence/pulse2jack/play[+rec].pa
- The original default file
  - $INSTALL_PREFIX/share/cadence/pulse2jack/play[+rec].pa

This is a partial solution for falkTX#234
@mead0w0
Copy link
Author

mead0w0 commented Feb 13, 2021

One thing to note is that because of the way Cadence detects pulse[0][1], the Pulse bridge tab will say "pulse is started but not bridged" even if you click the bridge button if you do not have a sink with the default client name "PulseAudio JACK Sink".

This didn't seem like an easy thing to fix unless we wanted to replace it with another hack, like checking the output of pacmd list-modules for module-jack-sink. It also seems like Cadence expects there to only be one jack sink module since there's only the one global for jackClientIdPulse.

We could remove the check for whether pulse is bridged and just output whether there was an error inside cadence-pulse2jack when starting pulse I suppose.

[0]

elif group_name == "PulseAudio JACK Sink":

[1]
elif group_name == "PulseAudio JACK Sink":

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant