1
0
Fork 0
mirror of https://github.com/polybar/polybar.git synced 2024-11-11 13:50:56 -05:00
Commit graph

11 commits

Author SHA1 Message Date
Patrick Ziegler
a520fead94
doc: Update description of polybar -m/-M (#2487)
It should be clear that `polybar -M` represents all valid monitor names.
2021-09-02 18:18:52 +02:00
Filip Banák
4ded401aab
Add initial support for an escape character (#2361)
Add a config parser method which, for now, deals only with escaping the
literal backslash character and logs an error message to inform the user
of the coming change.

The error message includes a properly escaped value for the user.

As a result of introducing an escape character('\'):

  - Warn the user of any unescaped backslashes, as they will not be
    treated as a literal character in the future

  - For now, still treat a single backslash as a literal character

  - Treat two consecutive backslashes as a single properly escaped
    literal backslash

Also:
  - Add documentation about the escape character to polybar(5) manpage
  - Add info about the escape character to changelog
  - Add testcases for ParseLineKeyTest
  - Add new test ParseEscapedValueTest

Resolves: First step in #2354

Improve value parsing

 - Take value arg in as an rvalue reference and move parsed value back
 - Remove unnecessary if statement
 - Rename function
 - Improve error message
 - Improve function description
 - Format

Add escape character documentation to manpages

Add information about the escape character to the polybar(5) manpage.

Add info about the esacape character to changelog

Add test cases for ParseLineKeyTest

Fix ParseLineKeyTest test cases

Also make config parser method parse_escaped_value private.

Add tests for escaped_value_parser method

Also remove unsued include statement

Simplify parse_escaped_value in config_parser

Remove unnecessary escaped value generation, so we do not have to keep
track of index differences.

Fix ParseEscapedValueTest test cases

Fix parse_escaped_value

Add more test cases for ParseLineKeyTest

Update CHANGELOG.md

Co-authored-by: Patrick Ziegler <p.ziegler96@gmail.com>

Adress review

 - Adjust documentation
 - Small code changes

Improve parse_escaped_value

Add initial support for an escape character

Add a config parser method which, for now, deals only with escaping the
literal backslash character and logs an error message to inform the user
of the coming change.

The error message includes a properly escaped value for the user.

As a result of introducing an escape character('\'):

 - Warn the user of any unescaped backslashes, as they will not be
   treated as a literal character in the future

 - For now, still treat a single backslash as a literal character

 - Treat two consecutive backslashes as a single properly escaped
   literal backslash

Resolves: First step in #2354

Improve value parsing

 - Take value arg in as an rvalue reference and move parsed value back
 - Remove unnecessary if statement
 - Rename function
 - Improve error message
 - Improve function description
 - Format

Add info about the esacape character to changelog

Add test cases for ParseLineKeyTest

Fix ParseLineKeyTest test cases

Also make config parser method parse_escaped_value private.

Add tests for escaped_value_parser method

Also remove unsued include statement

Simplify parse_escaped_value in config_parser

Remove unnecessary escaped value generation, so we do not have to keep
track of index differences.

Fix ParseEscapedValueTest test cases

Add more test cases for ParseLineKeyTest

Adress review

 - Adjust documentation
 - Small code changes

Remove duplicate testcase from ParseLineKeyTest

Add initial support for an escape character

Add a config parser method which, for now, deals only with escaping the
literal backslash character and logs an error message to inform the user
of the coming change.

The error message includes a properly escaped value for the user.

As a result of introducing an escape character('\'):

 - Warn the user of any unescaped backslashes, as they will not be
   treated as a literal character in the future

 - For now, still treat a single backslash as a literal character

 - Treat two consecutive backslashes as a single properly escaped
   literal backslash

Resolves: First step in #2354

Improve value parsing

 - Take value arg in as an rvalue reference and move parsed value back
 - Remove unnecessary if statement
 - Rename function
 - Improve error message
 - Improve function description
 - Format

Fix ParseLineKeyTest test cases

Also make config parser method parse_escaped_value private.

Remove duplicate testcase from ParseLineKeyTest
2021-01-26 19:16:29 +01:00
Kamui
89a723a4d9
feat(config): Try to load config.ini (#2324)
* Added .ini extension check to default config

* Added change to changelog and man page

* Added change to changelog and man page

* removed .vscode folder

* removed new lines in changelog
2020-12-23 17:52:30 +01:00
Patrick Ziegler
26a9bc5964
fix(doc): Typo (#2257)
Thanks to u/TheNextPoetician for reporting on reddit

Ref: https://www.reddit.com/r/Polybar/comments/k4llsx/typo_in_the_man_page/
2020-12-01 17:12:02 +01:00
patrick96
c34f013e5f doc: Reflect config fallback in config
This should reflect the changes from #2026
2020-11-23 13:16:37 +01:00
patrick96
cae3848030 logger: Add default logging level 'notice'
Between info and warning. Should be for things the user should be aware
of but not imply anything has to be done about it.
2020-04-22 00:38:31 +02:00
patrick96
fbbb5922da doc: Reword -m and -M description 2020-04-21 23:59:01 +02:00
patrick96
2edd8275ff Add -M CLI argument to display cloned monitors
Works the same as -m but doesn't purge cloned monitors
2020-04-21 23:59:01 +02:00
patrick96
fab8437ff1 doc: Write syntax definition in polybar.5 2020-02-21 16:17:12 +01: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
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