Commit Graph

568 Commits

Author SHA1 Message Date
ZyX 696478593d Move some functions out of classes
No need to have static methods that are not supposed to be overridden and that 
do not benefit from `self' argument they do not receive
2013-03-11 22:13:43 +04:00
ZyX 2c445a9356 Add more tests to test_configuration
Dynamic configuration tests. Purpose: make sure that default configuration does 
not throw. Tests catch only very trivial problems (like missing imports after
refactoring)
2013-03-11 22:09:34 +04:00
Kim Silkebækken 89204d2a7b Merge remote-tracking branch 'zyx-i/fix-278-powerline-lint' into develop 2013-03-11 16:24:35 +01:00
ZyX fe6f1bf4d5 Handle AttributeError also when importing segment function 2013-03-11 19:19:55 +04:00
ZyX 1ef1ad7cfe Add missing import 2013-03-11 19:19:42 +04:00
ZyX 24d662c823 Make lint more error-prone
Target: report as much errors as possible in a single run without failure
2013-03-11 19:19:28 +04:00
ZyX 9dc69d91ad Make Reader also produce MarkedError, remove JSONError 2013-03-11 19:19:09 +04:00
ZyX 49ad855eb5 Rename YAMLError to JSONError and MarkedYAMLError to MarkedError 2013-03-11 19:18:53 +04:00
ZyX 5da848fa4a Some fixes for flake8 2013-03-11 19:18:53 +04:00
ZyX 3fd1215091 Some changes to make it work in non-python2.7 2013-03-11 19:18:53 +04:00
ZyX f75bb9e65b Make parser less restrictive and able to report problems 2013-03-11 19:18:53 +04:00
ZyX d27f7a0411 Add most configuration checks
Changes:

- Add main configuration, colors.json, almost full themes and colorschemes
  checks
- Make powerline.lint.check return whether it had problems
- Make powerline-lint fail if .check reported problems
- Make tests run powerline-lint
- Add the script to the list of the installed scripts

Fixes #278
2013-03-11 19:17:18 +04:00
ZyX 287a88f473 Add JSON parser producing marked values
Ref #278
2013-03-11 19:14:35 +04:00
ZyX 5b11feac73 Make some functions be more convenient for use in lint checker 2013-03-11 19:12:32 +04:00
ZyX d33b8ee946 Fix highlight group documentation for line_percent 2013-03-11 19:12:15 +04:00
ZyX 9e8fab3312 Add highlight group data for powerline-lint 2013-03-11 19:12:03 +04:00
ZyX 7fca338315 Remove unused “colors” key 2013-03-11 19:11:51 +04:00
ZyX 551a2685f4 Move add_local_theme and get_theme to vim renderer
In any case for all other extensions they are useless. (Except for ipython, but
it is TODO and I am not going to use matchers this way, simple dictionary
lookup is better in this case.)
2013-03-11 19:11:32 +04:00
ZyX 657fcd1a99 Make @window_cached use @wraps
Otherwise documentation is not saved (hidden in decorated function only visible
in the closure).
2013-03-11 19:11:17 +04:00
ZyX ae62aee529 Renamed term_24bit_colors to term_truecolor 2013-03-11 19:11:10 +04:00
Kim Silkebækken 1773750485 Merge branch 'improved-ebuild' into develop 2013-03-11 15:53:46 +01:00
ZyX fdab80cd00 Add python-argparse dependency 2013-03-11 15:53:37 +01:00
ZyX 6c7e454fd8 Fix license
Fixes #299
2013-03-11 15:53:35 +01:00
ZyX 4374e1f71c Fix git/hg repo tests 2013-03-11 15:53:34 +01:00
ZyX a6d48232b0 Add python_test, more exclusions
Fixes #289
2013-03-11 15:53:32 +01:00
Kim Silkebækken 111eaa27e8 Combine vim modelines and Python encoding declarations
Ref #314
2013-03-11 10:40:09 +01:00
Peter Fern b31c987cc8 Add XDG_CONFIG_DIRS to config_paths for system-wide install
Commonly this will be `/etc/xdg/powerline`
2013-03-11 08:25:35 +01:00
Kim Silkebækken 8e8e9c9edc Merge remote-tracking branch 'pdf/ttf_output' into develop 2013-03-11 08:24:41 +01:00
Kim Silkebækken 6748701fcb Add vim modelines to all Python files
Added with `sed -i '2i# vim:fenc=utf-8:noet' `find -name '*.py'`` and
fixed in a couple of files without the UTF-8 encoding on top.

Ref #314
2013-03-11 08:11:25 +01:00
Kim Silkebækken 40fe38f641 Move argparser to powerline.shell so it can be re-used 2013-03-11 07:52:24 +01:00
ZyX 59ef974b29 Fix set statusline location, readd fix from #243
Ref #303
2013-03-11 07:16:30 +01:00
Kim Silkebækken 707cf2780c Cleanup .gitignore file 2013-03-11 07:13:57 +01:00
Kovid Goyal c70d3b38b6 Add bzr support 2013-03-11 07:09:42 +01:00
Peter Fern 38e2368682 Preserve style suffixes by inserting ForPowerline before any '-'s 2013-03-09 18:55:22 +11:00
Peter Fern bee1467484 Output in either otf or ttf (so we don't loose hinting/whatever) 2013-03-09 18:20:58 +11:00
Kim Silkebækken 20639494c0 Add Travis build status to README 2013-03-08 18:35:44 +01:00
Kim Silkebækken 6777fd41d4 Fix minor typo in powerline.vim 2013-03-08 18:03:57 +01:00
Kim Silkebækken 154d1aeac1 Fix issues in Arch Linux PKGBUILDS
Closes #291.
2013-03-08 18:02:03 +01:00
Kim Silkebækken 162f5ac55b Change license from CC BY-SA to the MIT license
Refs #299.
2013-03-08 17:58:06 +01:00
Kim Silkebækken be62815c0b Handle socket errors in IMAP mail segment 2013-03-04 15:13:58 +01:00
Kim Silkebækken cb87cfbe0f Update credits and PR guidelines 2013-03-03 22:11:39 +01:00
ZyX f6d23bdf7e Always return a string in email_imap_alert segment
Fixes #279
2013-03-03 21:05:06 +01:00
ZyX 4c233122d6 Do not restrict branches to `tests` branch
In any case it was not working
2013-03-03 21:03:56 +01:00
ZyX aa0a8bf76d Make tests support python2.6
Old unittest is not working for unknown reason, using unittest2 instead
2013-03-03 21:03:40 +01:00
ZyX 0a05b2961a Add support for with: statement to tests.vim
Also made everything use new vim_module._with where possible
2013-03-03 21:03:34 +01:00
ZyX c429d9eeb2 Omit using sys.modules if possible
Does not work though: still TypeError due to some global in multiproccessing
that got None
2013-03-03 21:03:34 +01:00
ZyX c334be416d Add tests.lib module with `replace_*()` with statement functions
Note: there is new problem: now multiprocessing() globals got assigned None
values. It is likely somehow related to extended `sys.modules` utilization
2013-03-03 21:03:26 +01:00
ZyX 584755765b Start adding tests
Tests are temporary disabled on all branches except tests (does not really work
though, needs travis.yml in all branches).
2013-03-03 21:03:19 +01:00
ZyX 2a39ed83d8 Use mode(1)
Otherwise all that fancy double-symbol modes are just not visible.
2013-03-03 21:03:19 +01:00
ZyX 47cfde0ecc Add support for python-2.6 2013-03-03 21:03:17 +01:00