a33e8de922
Defer parsing the version read from version.txt until it's about to be used, in order to fix an obscure bug involving indirect pkg_resources. When pkg_resources are imported, they override packaging with their own pkg_resources.extern.packaging. Depending on the system, this could either wrap the vendored pkg_resources._vendor.packaging or system packaging. For some reason, in the latter case the Version objects created prior to the wrapping are incompatible with the objects created afterwards. This causes the doc build to fail with: ``` Exception occurred: File "/tmp/polybar/build/doc/conf.py", line 249, in run if directive_version > version_txt: TypeError: '>' not supported between instances of 'Version' and 'Version' ``` This happens because apparently pkg_resources are imported indirectly somewhere between conf.py processing and running VersionDirective. Deferring version parsing until the latter guarantees that both objects are constructed at the same point in program flow and therefore use the same packaging package. |
||
---|---|---|
.. | ||
_static | ||
dev | ||
man | ||
user | ||
.gitignore | ||
CMakeLists.txt | ||
conf.py | ||
config.ini | ||
index.rst | ||
README.md |
Polybar Manual
The official polybar documentation lives here.
The html documentation and man pages are built automatically when you build with cmake (cmake creates the custom
target doc
).
Preview Locally
The documentation uses Sphinx to generate the documentation, so you will need to have that installed.
If you build polybar normally while having Sphinx installed during configuration, the documentation will be enabled and
built as well. Building the documentation can be disabled by passing -DBUILD_DOC=OFF
to cmake
.
Once configured, all of the documentation can be generated with make doc
or use make doc_html
or make doc_man
to
only generate the html documentation or the man pages respectively.
The HTML documentation is in doc/html/index.html
in your build directory and the man pages are in doc/man
.