Commit Graph

258 Commits

Author SHA1 Message Date
Kim Silkebækken 51c302a6ca Revert to previous way of sourcing vim plugin
Refs #95.
2013-01-22 17:14:47 +01:00
ZyX 0d39dd5507 Add installation of powerline.vim into /usr/share/vim/vimfiles/plugin 2013-01-22 17:10:11 +01:00
ZyX 6bc13b8d60 Make g:powerline_* variables fixed*, added g:powerline_loaded
The latter is required to be able to forbid sourcing powerline.vim

* changes are ignored until script is resourced
2013-01-22 17:10:01 +01:00
Kim Silkebækken f175a6babb Fix issue with $pipestatus
$pipestatus is a space-separated int list and not a single int.
2013-01-22 16:45:31 +01:00
Kim Silkebækken 8f055473ac Update tmux theme and add sourceable config file
The tmux theme has been updated and now matches the other themes much
better. It may still look a little boring and segment cropping isn't
enabled, but it's a good starting point. It colors the weather segment
differently based on the current weather and temperature, and some other
segment colors have been tweaked.

To enable the theme, add the following to your tmux.conf:

    source '/full/path/to/powerline/bindings/tmux/powerline.conf'

Closes #51.
2013-01-22 16:36:50 +01:00
Kim Silkebækken 96760675ea Add "e" symbol before virtualenv prompt segment 2013-01-22 14:59:07 +01:00
Kim Silkebækken 7c19381b24 Update optional dependency list 2013-01-22 14:23:21 +01:00
Kim Silkebækken 504e212f14 Add common virtualenv segment 2013-01-22 14:19:04 +01:00
Kim Silkebækken 35de8a192b Fix common cwd segment for absolute paths 2013-01-22 14:09:02 +01:00
Kim Silkebækken c5df2fcb7c Create awesome looking prompt with divided cwd
This is inspired by the look of powerline-shell:
https://github.com/milkbikis/powerline-shell
2013-01-22 14:03:54 +01:00
Kim Silkebækken a023f4ad10 Add bash prompt script for sourcing in bashrc
This only displays the left part of the prompt. It requires the
left-only theme to be able to display all segments.

The script must be sourced with an absolute path for now:

    . /path/to/powerline/bindings/bash/prompt.sh

Closes #90.
2013-01-22 13:45:03 +01:00
Kim Silkebækken 9035ec73f9 Add left-only shell theme
This is useful for bash prompts since bash doesn't support RPS1. This
theme must be manually enabled by editing the user config file.

Closes #84.
2013-01-22 13:36:40 +01:00
Kim Silkebækken 487aef3af7 Add zsh prompt script for sourcing in zshrc
This script sets a couple of environment variables in tmux if it's
running, and provides the last exit code and last pipe status to
powerline-prompt. It also traps SIGWINCH and sets the window width as an
env variable in tmux. The default prompt has been split in two and the
git branch is moved to RPS1.

The script must be sourced with an absolute path for now:

    . /path/to/powerline/bindings/zsh/prompt.zsh

Statusline cropping has not been implemented in powerline-tmux yet.

Closes #82.
Closes #83.
Refs #90.
2013-01-22 13:25:01 +01:00
Kim Silkebækken cfe47adc96 Move branch segment to right side in shell theme 2013-01-22 13:23:29 +01:00
Kim Silkebækken 30f98f6dc2 Add exit code/pipe status args in powerline-prompt
Refs #90.
2013-01-22 13:22:35 +01:00
Kim Silkebækken eb141428c6 Return empty string for empty sides 2013-01-22 13:21:54 +01:00
Kim Silkebækken b7e7b1e4f7 Use absolute import in source_plugin.vim
Refs #95.
2013-01-22 13:20:26 +01:00
Kim Silkebækken 292d5313e2 Remove expensive functools.wraps from memoize decorator 2013-01-22 13:17:58 +01:00
Kim Silkebækken 10ed88c576 Update vim soft divider highlighting 2013-01-22 11:44:46 +01:00
Kim Silkebækken 3703514ed7 Add option to set soft divider highlighting group
Closes #89.
2013-01-22 11:26:33 +01:00
Kim Silkebækken 424f979136 Make it possible to return several segment in segment functions
This requires a couple of minor changes to custom segments. The segment
`highlight` key has been renamed to `highlight_group`, and segment
functions must return a list of segments dicts instead of just a dict.

Closes #88.
2013-01-22 10:58:41 +01:00
Kim Silkebækken 973ea572d4 Remove unneeded exclusion from MANIFEST.in 2013-01-22 09:07:22 +01:00
Kim Silkebækken f800872c9e Default to no mode in renderer.render() method 2013-01-22 09:06:30 +01:00
Kim Silkebækken 2b0c01482b Improve side handling in prompt/tmux scripts 2013-01-22 09:04:57 +01:00
Kim Silkebækken 2159814076 Add side argument in renderer.render() method 2013-01-22 09:03:34 +01:00
Kim Silkebækken 3ee6e55025 Handle Py2/3 Unicode differences when writing to stdout
Closes #94.
2013-01-22 08:05:37 +01:00
Kim Silkebækken 8355e3d670 Move string decoding of file name/dir vim segments
Closes #93.
2013-01-21 22:09:32 +01:00
Kim Silkebækken ced333dd29 Add note about Python 3 support in docs 2013-01-21 22:03:56 +01:00
Kim Silkebækken a620a0ef54 Fix various Python 3 related issues
Powerline now detects the Python version and verifies that the user has
Python 3.3 before enabling Python 3 support. To enable Python
3 support, use `python3` to execute source_plugin() in your vimrc
  instead of `python2`.
2013-01-21 21:50:30 +01:00
Kim Silkebækken 85331710bf Remove unneeded extras dependency 2013-01-21 21:02:36 +01:00
Kim Silkebækken bee427eb42 Add Python 3.3 support
Support for unicode literals was reintroduced in Python 3.3 which makes
supporting both Python 2 and Python 3 much easier, so this will be the
minimum supported Python 3 version.

Closes #8.
2013-01-21 20:42:57 +01:00
Kim Silkebækken 77f66cbbc9 Add additional dependency info 2013-01-21 20:38:41 +01:00
Kim Silkebækken 614c08bee1 Convert file name to UTF-8 in vim file name segment
Closes #87.
2013-01-21 17:55:05 +01:00
Kim Silkebækken e64ef3c337 Fix zsh prompt example 2013-01-21 17:30:35 +01:00
Kim Silkebækken 8192d59284 Make system load thresholds customizable 2013-01-21 11:46:14 +01:00
Kim Silkebækken 4a9ade11b5 Make uptime tmux segment support psutil
psutil is used if available, and the function falls back to reading
/proc/uptime if not. According to the psutil docs this should work
across more platforms.
2013-01-21 11:45:13 +01:00
Kim Silkebækken 25c5a6d978 Update zsh prompt example in docs 2013-01-21 10:53:51 +01:00
Kim Silkebækken fcb07943eb Allow side, extension and renderer module to be specified in powerline-prompt
Refs #84.
2013-01-21 10:51:19 +01:00
Kim Silkebækken 2eb07e894e Add zsh prompt renderer
Zsh can use regular escape sequences in the prompt, but they must be
wrapped in %{...%} to work correctly.

Refs #84.
2013-01-21 10:49:03 +01:00
Kim Silkebækken 0b385a11e0 Rename "terminal" extension to "shell"
Refs #84.
2013-01-21 10:48:14 +01:00
Kim Silkebækken 45769b2907 Allow overriding the renderer when instantiating Powerline
This is useful to allow e.g. the prompt script to use a common shell
theme while having different renderers for different shells.
2013-01-21 10:31:16 +01:00
Kim Silkebækken 7be62ba563 Use code-blocks in docs 2013-01-21 10:16:34 +01:00
Kim Silkebækken 7db8aa074f Update usage docs
Refs #79.
2013-01-21 10:14:23 +01:00
Kim Silkebækken ccc18e8401 Remove unnecessary import 2013-01-21 09:56:43 +01:00
なつき 4e97fd95d8 Add Pathogen/Vundle support
Closes #79.
2013-01-21 09:56:01 +01:00
Kim Silkebækken c561922eed Add info about Gentoo Live ebuild 2013-01-20 19:49:06 +01:00
Kim Silkebækken 84edefbe2e Update docs with new module paths 2013-01-20 19:48:56 +01:00
ZyX b7d8495b9c Fix problems in mode segment
- It was impossible to configure visual block and select block mode strings:
  JSON strings can contain neither raw control characters nor escape sequences
  for them
- It was impossible to override only some of the strings:
  missing key generates KeyError exception, not IndexError
2013-01-20 19:39:59 +01:00
ZyX f1976c2022 Update docs
- Added notes about where common and extension-specific configuration is located
- Added common.paths config.json option description
- Fixed user-defined segments location found in segments section
- Fixed Themes/segments/module reference text
2013-01-20 19:39:59 +01:00
ZyX 69846cd0cc Move configuration files into separate directory
Refs #72.
2013-01-20 19:39:59 +01:00