Skip to content

PHPL_Config_Tool

Christopher Vagnetoft edited this page Dec 17, 2016 · 1 revision

phpl is configured using the phpl-config tool. Internally, this updates the configuration before calling phpl-reload to activate the changes.

Listing items

To see what is in your powerline, use the -l or --list option:

$ phpl-config -l

To see what items are available to add, instead use -L or --list-modules:

$ phpl-config -L

Adding, removing and editing

Adding is done with -i or --insert. You need to specify the module to add, and in case you need more than one of a specific module also a custom name using -n or --name:

$ phpl-config -i text -n mytext

Where the item is added is determined using the --before, --after, --first and --last options. First and last don't need any values, but before and after need the name of another item on the prompt. If nothing is specified, the new item will be added as second to last.

$ phpl-config -i text -n mytext --first

Most modules also take options, as indicated in the output from --list-modules. To set an option, use -s together with the option name and the value separated by an equal sign. This can be done when inserting (-i) or editing (-e) items.

$ phpl-config -i text -n mytext --first -stext="This is the text"
$ phpl-config -e mytext -stext="And it can be edited"

If you need to make a lot of changes in a go, for example when calling from a script, you can use --no-reload. Just remember to call phpl-reload afterwards:

$ phpl-config --no-reload ...
$ phpl-reload --prompt

Themes

To change the theme, use phpl-config --theme with the name of the theme to use. To get a list of the themes, do --theme list.

Clone this wiki locally