Question

For functional tests of powerline script in a controlled environment I need an option that will make fish not load any configuration files as code from them may spoil the test output. With zsh I would simply write zsh -f -i. With bash I would use bash --noprofile --norc -i. What should I do with fish?

I would rather prefer to avoid heavy solutions like using virtual machines.

Was it helpful?

Solution

fish relies on its own configuration files to bootstrap itself, so I'm going to assume you mean "without user-specified configuration files" and not "without any configuration files at all."

Unfortunately there's no equivalently simple option for this. The best hack I can think of is to set the env var XDG_CONFIG_HOME to an empty or non-existent directory, before invoking fish. This will change where fish looks for user-provided config files, and so will fail to load them.

An option to support this directly seems like a reasonable request, useful for tracking down bugs, so I'm keen to add it. If you'd like to open an issue we'd appreciate it; otherwise I can do it. Thanks!

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top