Commit Graph

1539 Commits

Author SHA1 Message Date
patrick96
2b0bf463b1 config: Remove bspwm variable references
This confuses lots of people when removing the bspwm module from the
sample config and trying to use the i3 module
2019-06-02 15:36:26 +02:00
patrick96
7724c4dccb rtd: Use provided version string on rtd
@APP_VERSION@ isn't available on rtd because it doesn't configure the
entire project
2019-05-17 17:03:51 +02:00
Jérôme BOULMIER
28b8877edc cleanup(cmake): remove useless variables (#1767)
They also caused a cmake warning when compiling with debug symbols
2019-05-17 16:51:16 +02:00
patrick96
e1e28f09f3 refactor(build): Remove version number namespace
I don't know the original intention behind this but it clutters up debug
traces and basically makes ccache useless.

The only benefit it has, giving version info in stacktraces, is kind of
void since we already ask for version information on github issues.
2019-05-17 16:49:47 +02:00
Sebastian Graf
cb75857ff6 pulse: Set volume to max when the increase was too huge (#1765)
Previously, when volume was in close proximity to n_max_volume, a larger
increase would not do anything. After this patch, volume is set to
m_max_volume in such scenarios. If the volume already is at
n_max_volume, we mirror the old behavior and emit a warning.

So, for example, consider m_max_volume was 100%, but the volume prior
to the increase was 96%. An increase of 5% would do nothing (emit a
warning, even) instead of setting the volume to 100%.

Note that this might happen even if the volume is at 95% according to
%percentage% due to rounding errors.
2019-05-14 22:06:14 +02:00
Roberto Santalla
b2b73b5d91 feat(battery): add %percentage_raw% token (#1756)
Displays real percentage instead of being set to 100 if percentage > full-at

* battery: added percentage_raw token, which ignores full-at

* battery: current_percentage returns raw, added clamping function instead

* battery: clamp percentage used by build()
Made clamp_percentage() const to allow its usage inside build()

* battery: read and return percentage in one line
2019-05-14 15:01:54 +02:00
patrick96
65e72fd71e travis: Build documentation 2019-05-10 08:14:02 +02:00
patrick96
4c0117528e build: Allow doc to build as its own project
We can now build the docs without having to have installed all
dependencies for polybar.
2019-05-10 08:14:02 +02:00
patrick96
9103d232a5 build: Remove -Werror
Whenever a new gcc version is released that introduces new warnings,
this breaks lots of builds on the user's side. This change pushes the
detection of these new warnings a bit back until either a user reports
warnings or developers get the new compiler updates. I think this is a
good tradeoff since release builds are no longer totally broken as soon
as a new compiler version comes out.

Travis still uses -Werror because there we actually want builds to fail.
2019-05-08 12:23:48 +02:00
patrick96
37a7ad9c44 migration: Update submodule URLs 2019-05-08 12:20:33 +02:00
patrick96
4cc836fa66 migration: Update URLs
jaagr/polybar -> polybar/polybar

Travis changed their url for new projects to travis-ci.com
2019-05-08 12:20:33 +02:00
Sergi Jimenez
9f7840c7d6 fix(build): Uninitialized local variable (#1759)
Fixes #1758
2019-05-05 22:09:03 +02:00
patrick96
f1061e1217 doc: add rtd badge 2019-04-24 08:11:27 +02:00
patrick96
01b326c10f move shell completion to contrib folder
Now the doc folder is exclusively for documentation
2019-04-24 08:11:27 +02:00
patrick96
bfaeb71cb8 build: create config even when docs are disabled
Fixes #1733
2019-04-24 08:11:27 +02:00
patrick96
f68a5e6ccf build: Add build type specific flags to -vvv 2019-04-24 08:11:13 +02:00
patrick96
d5112c9b66 git: Remove include .gitignore
The settings.hpp file is now generated in the build folder and doesn't
need to be included in the gitignore

Ref #1726
2019-04-08 09:01:48 +02:00
patrick96
0ab9fcdc38 refactor: Remove all mentions of icon_t
Is exactly the same label_t
2019-04-08 09:01:48 +02:00
patrick96
148d46b65b build: Remove Makefile from root
Does basically the same as build.sh
2019-04-08 09:01:48 +02:00
patrick96
d1fe97b90f git: Clean up gitignore
Each directory is responsible for ignoring files
2019-04-08 09:01:48 +02:00
patrick96
0251a80e75 build: Remove C compiler
There isn't a single .c file in the project. It just added bloat
2019-04-08 09:01:48 +02:00
patrick96
a67b824e25 cmake: Make Release default build type
The polybar executable with RelWithDebInfo gets over 100MB. And there
really isn't any reason to have users install such huge executables.

Release build type gives you approx. 3.6M executables

Fixes #1497
2019-04-08 09:01:48 +02:00
Kazufumi NOTO
7414e98008 feat(temp): Configurable lower bound for ramp (#1706)
Similar to warn-temperature, temps below `base-temperature` will use the first ramp icon.

Closes #1703
2019-04-07 18:36:09 +02:00
Jérôme BOULMIER
fca4151f36 fix(window): remove useless operator= and add default copy cstr (#1729)
Fixes compilation under GCC 9

The default copy constructor implicit generation is deprecated by C++ standard.

The window& operator=(const xcb_window_t win); operator seems to be useless.

Fixes #1728
Ref jaagr/xpp#16
2019-04-07 17:32:55 +02:00
Jérôme BOULMIER
627c4ac2af fix(brightness): reading brightness in actual_brightness (#1689)
As the kernel documentation said:
https://www.kernel.org/doc/Documentation/ABI/stable/sysfs-class-backlight

    This file will also show the brightness level stored in the driver, which may not be the actual brightness (see actual_brightness).

Therefore the brightness value should be read in the actual_brightness file.

Fix #1180
2019-04-07 17:04:55 +02:00
patrick96
7d0c6300f6 cmake: put version string into version.txt 2019-04-05 23:43:37 +02:00
patrick96
72db0538e1 doc: Add copyright 2019-04-05 23:43:37 +02:00
patrick96
bbdcbee068 doc: Make conf.py work on readthedocs
rtd scans the project for a conf.py file so we cannot name it conf.py.in
unless we get rtd to run cmake before building.

The easier option is to have doc/conf.py be the file used by rtd and all
other builds use cmake to first configure it.
2019-04-05 23:43:37 +02:00
patrick96
3111bee143 doc: Remove sphinx theme from readme
For local previews the sphinx_rtd_theme is not used, only in read the
docs.
2019-04-05 23:43:37 +02:00
patrick96
aec34c11f1 aur: Add python-sphinx to polybar-git makedepends
Not yet to 'polybar' package that will be done in the next release
2019-04-05 23:43:37 +02:00
patrick96
5b7bb2514e refactor(doc): Enable only if sphinx is available 2019-04-05 23:43:37 +02:00
patrick96
73de9257a1 refactor(cmake): Remove unused querybin 2019-04-05 23:43:37 +02:00
patrick96
1ed8ddd251 travis: Disable doc generation
Travis doesn't have sphinx installed by default and it's also the wrong
version for our documentation
2019-04-05 23:43:37 +02:00
patrick96
a1cccef251 refactor(doc): Use default theme for local builds
The sphinx_rtd_theme takes up about 7.8MB because it includes a lot of
fonts. The default theme only takes 600KB
2019-04-05 23:43:37 +02:00
patrick96
754673bff8 refactor(cmake): Make documentation optional 2019-04-05 23:43:37 +02:00
patrick96
3596001de1 refactor(cmake): Add version information to summary 2019-04-05 23:43:37 +02:00
patrick96
243a6a84a6 refactor(cmake): Use exit code of git describe 2019-04-05 23:43:37 +02:00
patrick96
2c42bae09f refactor(doc): Use cmake APP_VERSION in conf.py
This also moves the doc generation completely into cmake (no more
Makefile).

To generate the docs the project needs to first be configured and then
`make doc` can be run.

The approach used is leaned on the cmake's project own use of Sphinx:
Utilities/Sphinx/CMakeLists.txt
2019-04-05 23:43:37 +02:00
patrick96
fc2d2db76f refactor(cmake): Determine version in cmake
We need to have the version string available in multiple places not just
the source code. It is now hardcoded in the root CMakeLists.txt and all
files that need it will be configured with cmake.

This also removed the unecessary duality of GIT_TAG and APP_VERSION and
GIT_TAG_NAMESPACE and APP_VERSION_NAMESPACE.
2019-04-05 23:43:37 +02:00
patrick96
800d24c92f doc: Add readme with local preview instructions 2019-04-05 23:43:37 +02:00
patrick96
166f704e58 doc: Install rst based man pages 2019-04-05 23:43:37 +02:00
patrick96
1e361fa9ca doc: Add manpage as rst file
This allows us to also have the manual as part of the generated html
documentation.

The syntax is also easier to use.

Right now the man page installed on the system is not replaced with the
rst file, this will come in a later step
2019-04-05 23:43:37 +02:00
patrick96
c841bd512c doc: Build doc with cmake
Run `make doc` inside the cmake build folder.

The html output is installed to
${CMAKE_INSTALL_PREFIX}/share/doc/polybar
2019-04-05 23:43:37 +02:00
patrick96
7809be8d58 doc: Setup in-repo documentation 2019-04-05 23:43:37 +02:00
Jérôme BOULMIER
57b8fcc7cd refactor(cmake): move generated files in build directory (#1726) 2019-04-04 22:53:54 +02:00
Patrick Ziegler
cff13214ff
fix(aur): Patch release in polybar-git package (#1724)
The polybar-git PKGBUILD should not be updated for patch releases
2019-04-03 08:07:47 +02:00
Patrick Ziegler
253f44caaa
aur: Update to 3.3.1 (#1723) 2019-04-03 07:53:34 +02:00
DrunkenChicken
25f99c0a61 fix(xworkspaces): active ws upon ws deletion (#1713)
Active desktop was tracked via it's index, but when desktops are removed from `_NET_DESKTOP_NAMES` that index may become invalid.

Fixes #1710
2019-04-01 18:04:44 +02:00
Jérôme BOULMIER
31a25af3d3 fix(tray): fix offset for negative percentage (#1669)
tray-offset-{x,y} were clamped between [0, max_value] rather than [-max_value, max_value]. Therefore negative percentage were ignored.

Fixes #1666
2019-03-22 09:55:08 +01:00
Kazufumi NOTO
82b9ea8a09 fs: Fix incorrect size report on 32bit machines (#1699)
Cast before multiplication to avoid overflow.

Fixes #743
2019-03-18 18:16:42 +01:00