DeaDBeeF-Player / deadbeef

DeaDBeeF Player
https://deadbeef.sourceforge.io/
Other
1.62k stars 176 forks source link

Request: --config /path option Please #2775

Closed 0pLuS0 closed 1 year ago

0pLuS0 commented 2 years ago

Steps to reproduce the problem

When running deadbeef -h these are the only options I see it has to run with.

 >deadbeef -h
starting deadbeef 1.8.8
Usage: deadbeef [options] [--] [file(s)]
Options:
   --help  or  -h     Print help (this message) and exit
   --quit             Quit player
   --version          Print version info and exit
   --play             Start playback
   --stop             Stop playback
   --pause            Pause playback
   --toggle-pause     Toggle pause
   --play-pause       Start playback if stopped, toggle pause otherwise
   --next             Next song in playlist
   --prev             Previous song in playlist
   --random           Random song in playlist
   --queue            Append file(s) to existing playlist
   --gui PLUGIN       Tells which GUI plugin to use, default is "GTK2"
   --nowplaying FMT   Print formatted track name to stdout
                      FMT %-syntax: [a]rtist, [t]itle, al[b]um,
                      [l]ength, track[n]umber, [y]ear, [c]omment,
                      copy[r]ight, [e]lapsed
                      example: --nowplaying "%a - %t" should print "artist - title"
                      for more info, see http://github.com/DeaDBeeF-Player/deadbeef/wiki/Title-formatting
                      NOTE: --nowplaying is deprecated.
   --nowplaying-tf FMT  Print formatted track name to stdout, using the new title formatting
                      FMT syntax: http://github.com/DeaDBeeF-Player/deadbeef/wiki/Title-formatting-2.0
                      example: --nowplaying-tf "%artist% - %title%" should print "artist - title"
   --volume [NUM]     Print or set deadbeef volume level.
                      The NUM parameter can be specified in percents (absolute value or increment/decrement)
                      or in dB [-50, 0] (if with suffix).
                      Examples: --volume 80, --volume +10, --volume -5 or --volume -20dB

What's going on? Describe the problem in as much detail as possible.

Can you please consider adding in a --config option, that we can run deadbeef with, pointing to the deadbeef /config/file(s) we want to run?

I personally have 3 different deadbeef layouts I use in Linux, so for now, I just have them listed like this in the ~/.config/path;

deadbeef.radio deadbeef.compact deadbeef.lyrics

I know most people might only make one layout and use it for everything, I just like having seperate layouts for their intended purpose(s) when I want it. I personally don't like the one size fits all approach and I don't always use, or need it, and for me, using only one layout just becomes bloated and confusing, with to much going on, hence the main reason why I created different layouts, to keep it simple and light weight.

So it woud be really great if I could run deadbeef like;

deadbeef --config ~/.config/deadbeef.radio and it loads the correct config, playlists, etc...

Information about the software:

Deadbeef version: 1.8.8 OS: Slackware 15.0

Thanks for your considersation on this, greatly appreciated, keep up the great work, I love deadbeef!

w-jablonski commented 1 year ago

@0pLuS0 maybe you could achieve sth similar by using the command XDG_CONFIG_HOME="/my/config/dir" deadbeef or the Path=/my/config/dir line in your .desktop file?...

0pLuS0 commented 1 year ago

Well, for now, .desktop, XDG_CONFIG_HOME=, or simply renaming the directories back to just deadbeef, there still seems to be manual intervention needed on my part, it's not like there is just some solution, to simply run them, without having to make these changes somewhere.

For now I just rename the directories when I want to use one, seems simple enough, until something gets implemented.

Oleksiy-Yakovenko commented 1 year ago

Yes, using XDG_CONFIG_HOME is the right way. I'm using it for the same purpose -- also it lets me run multiple instances of deadbeef at the same time. I don't believe adding a --config option would have any value.

0pLuS0 commented 11 months ago

@Oleksiy-Yakovenko

How are you using XDG_CONFIG_HOME to run multiple instances, and where did you define XDG_CONFIG_HOME at?

THANKS

Oleksiy-Yakovenko commented 11 months ago

It's an environment variable, you just pass it as you would do with any other variable in shell. for example: XDG_CONFIG_HOME=/home/username/ddbhome deadbeef will run deadbeef with the customized variable, and will allow to running it in parallel with another instance which uses different path.

0pLuS0 commented 11 months ago

I know it's an environment variable, I was just looking at it, like you mainly see it in the user-dirs.dirs file.

So I was asking, where are you defining the command at, in like a bash/zsh profile, etc.?

Or .desktop files?

THANKS

Oleksiy-Yakovenko commented 11 months ago

I'm typically using this during development / for testing, so I configure this in Xcode. I never put it in any shell configuration files like bash etc. In the rare case when I need to do this outside of Xcode, I directly specify it on command line. I don't know what is your use-case, so can't really suggest where you should put it.

0pLuS0 commented 11 months ago

Ok...

THANKS