samtools / bcftools

This is the official development repository for BCFtools. See installation instructions and other documentation here http://samtools.github.io/bcftools/howtos/install.html
http://samtools.github.io/bcftools/
Other
678 stars 240 forks source link

Permanent configuration of BCFTOOLS_PLUGINS path #2268

Closed gevro closed 2 months ago

gevro commented 2 months ago

Hi, Is there a way to configure this permanently within the bcftools path, for example in a config file? As opposed to defining this environment variable each time.

Or making a default search path that at least includes the 'plugins' directory present in the same directory as the bcftools binary.

jkbonfield commented 2 months ago

Specify it build time with ./configure --with-bcf-plugin-path=PATH

gevro commented 2 months ago

Thanks so much. I think it would be helpful if it at least also searched the path of the binary.

jkbonfield commented 2 months ago

Finding the path of a binary is non-trivial. See https://stackoverflow.com/questions/1023306/finding-current-executables-path-without-proc-self-exe/1024937#1024937 for the full horror. So this isn't viable.

pd3 commented 2 months ago

The way the question is phrased, and since a config file was suggested as a possible solution, it makes me think you might be asking something more trivial: one can set the environment variable via .bashrc or .profile.

gevro commented 2 months ago

Yes, that works too. Thanks.