Commit graph

274 commits

Author SHA1 Message Date
syl20bnr
a2de9a63af Use :toggle keyword instead of when forms 2016-05-29 22:39:21 -04:00
sooheon
15e6290151 Make check for company-mode explicit, not implicit
People may have company-mode installed without necessarily using the
auto-completion layer.
2016-05-27 00:32:05 -04:00
syl20bnr
1f993bddf6 Rename spacemacs-helm and spacemacs-ivy layers to helm and ivy
For ivy users: be sure to update your dotfile by replacing spacemacs-ivy
by ivy
2016-05-15 22:24:27 -04:00
bmag
6edef36b17 Call python-setup-shell only once, not from hook 2016-05-06 12:59:51 +02:00
Xiao Hanyu
c93e47028c Set comment-inline-offset to 2 for python-mode.
Since python's PEP8 recommends two spaces for inline spaces.

Ref:
- https://www.python.org/dev/peps/pep-0008/#inline-comments
2016-04-21 22:26:18 -04:00
Christoph Paulik
643553a0fe Only disable semantic-idle-summary in python if anaconda-mode is used.
Some people have problems with anaconda mode and exclude it. This
enables them to at least have the semantic summary in their modeline.
2016-04-21 21:13:53 -04:00
Junhui
9d1b574554 Make pylookup.py compatible with Python 2 and 3 2016-04-21 21:08:31 -04:00
Eivind Fonn
7f95d250db python: Move smartparens config to correct place 2016-04-18 15:56:16 +02:00
syl20bnr
47776e8999 python: move semantic config and fix error with semantic-idle-summary-mode
Move all semantic related config to semantic post-init and correctly
fix the error with void function semantic-idle-summary-mode when
opening a python without the semantic layer enabled.
2016-04-17 00:37:47 -04:00
Neal D. Becker
4ca8b55819 set semantic-idle-summary-mode on hook 2016-04-17 00:37:47 -04:00
Christoph Paulik
a175de5b7a Use py-yapf from MELPA. 2016-04-12 22:58:41 -04:00
syl20bnr
6c2665e0f7 python: move disable semantic hook to anaconda init function 2016-04-12 22:38:48 -04:00
Junhui
95be4bce44 Fix 'makefile' for pylookup 2016-04-11 20:40:42 +02:00
Fabien Dubosson
ddc831e061 [python] Correct whitespaces in packages.el 2016-04-11 20:38:01 +02:00
Christoph Paulik
d38ce800bd Disable semantic-idle-summary in Python mode.
Anaconda provides more useful information but can not do it properly
when this mode is enabled since the minibuffer is cleared all the time.

Fix #5564
2016-04-11 20:35:40 +02:00
Joe Hillenbrand
d3922095e2 python: register python language for org-babel 2016-04-07 23:02:55 -04:00
Muneeb Shaikh
c9ef2f6f3c python: explicitly autoload py-yapf-buffer
Since it's a local package, there's no autoloads file. Adding it to
:commands to let use-package add autoload for it.
2016-04-04 21:46:23 -04:00
syl20bnr
e511a1211c python: lazy load py-yapf 2016-04-03 00:36:06 -04:00
syl20bnr
3b0c1fd93d Convert org doc files with doc-fmt 2016-03-30 22:59:55 -04:00
syl20bnr
5495c8dff2 python: correctly mark python package as built-in 2016-03-26 03:24:35 -04:00
syl20bnr
82fdd9a511 Use evil in holy-mode
Motivation

While disabling Evil in holy-mode makes its implementation shorter and
sounds elegant on the paper, in practice it puts a big burden on the
configuration parts which need to know if Evil is enable or not. This is
a bad separation of concerns and the bunch of fixes that we were forced
to do in the past weeks shows this issue. Those fixes were about
removing the knowledge of the activation of Evil by implementing new
dispatching functions to be used by layers, this is cumbersome and makes
Spacemacs layer configuration more subtle which is not good. There was
additional bad consequences of the removal of Evil state like the
impossibility to use Evil lisp state or iedit states, or we would have
been forced to implement a temporary activation of Evil which is
awkward.

Instead I reintroduce Evil as the central piece of Spacemacs design thus
Evil is now re-enabled in holy-mode. It provides the abstraction we need
to isolate editing styles and be able to grow the Spacemacs
configuration coverage sanely. Layers don't need to check whether the
holy mode is active or not and they don't need to know if Evil is
available (it is always available). We also don't need to write
additional dispatching functions, this is the job of Evil, and I think
it provides everything for this. Ideally configuration layer should be
implemented with only Evil in mind and the holy-mode (and hybrid-mode)
should magically make it work for Emacs style users, for instance we can
freely use `evil-insert-state` anywhere in the code without any guard.

Evil is now even more part of Spacemacs, we can really say that
Spacemacs is Emacs+Evil which is now an indivisible pair. Spacemacs
needed this stable API to continue on the right track.

While these changes should be rather transparent to the user, I'm sorry
for this experimental period, I failed to see all the implications of
such a change, I was just excited about the possibility to make Evil
optional. The reality is that Spacemacs has to embrace it and keep its
strong position on being Emacs+Evil at the core.

Implementation

- insert, motion and normal states are forced to emacs state using an
advice on `evil-insert-state`, `evil-motion-state` and
`evil-normal-state` respectively. These functions can be used freely in
the layer configuration.
- A new general hook `spacemacs-editing-style-hook` allow to hook any
code that need to be configured based on the editing style. Functions
hooked to this hook takes the current style as parameter, this
basically generalize the hook used to setup hjkl navigation bindings.
- ESC has been removed from the emacs state map.
- Revert unneeded changes
  - Revert "evil: enter insert-state only from normal-state"
    commit bdd702dfbe.
  - Revert "avoid being evil in deft with emacs editing style"
    commit f3a16f49ed.

Additional changes

All editing style packages have been moved to a layer called
`spacemacs-editing-styles`

Notes

I did not have time to attack hybrid mode, I should be able to do it
later.
2016-03-13 21:16:55 -04:00
Eivind Fonn
411be27ed1 Remove enable-semantic-mode function
- No reason to require semantic manually
- Don't set submodes in a hook function (hard to change for user)
2016-03-10 23:13:19 -05:00
Allen Li
974c92e758 Make pylookup use std completing-read function 2016-03-03 20:51:18 +01:00
justbur
39e06feba9 Use unless-debug version of condition-case
It's not possible to get full backtraces in these instances when an
error is signaled, and I think we should generate full backtraces when
debug-on-error is enabled as a general rule.

I had to make this change at one place to track down the root of problem
2 in #5200.
2016-03-03 20:30:30 +01:00
darkfeline
6d331bc5a4 Fix pylookup binding
Fix pylookup binding
2016-02-24 23:18:56 -08:00
justbur
e69d5500bc evil-jumps: Fix old function names
evil-jumper--push is now evil--jumps-push
2016-02-23 20:45:18 +01:00
Alejandro Catalina
bdd702dfbe evil: enter insert-state only from normal-state 2016-02-23 20:42:59 +01:00
Eivind Fonn
f3a15840b9 Add anaconda-eldoc-mode 2016-02-16 23:02:07 -05:00
justbur
aab007d225 evil-jumper: Remove obsolete package
The functionality is now incorporated into the evil core and this
package has been marked as obsolete.
2016-02-16 21:23:07 -05:00
Fabien Dubosson
06cb27e1dc [doc] Fix some additional SPC : to SPC SPC 2016-02-07 14:39:54 +01:00
Jaakko Luttinen
34df7b03b0 Add key binding for going back in anaconda mode
There are keybindings `C-o` and `M-*` to go back already, but it could
be a good idea to add an entry to `SPC m g` (or `, g`) menu where the
other movement commands are.
2016-02-02 21:23:17 +01:00
Eivind Fonn
e29ac21345 Register all REPLs and make SPC m ' bindings 2016-01-31 23:39:25 -05:00
Eivind Fonn
e9f8377b92 Tweak flycheck loading process 2016-01-31 23:04:48 -05:00
Fabien Dubosson
7f201b5b98 Fix parenthesis code style in Python packages 2016-01-31 21:48:52 +01:00
Christoph Paulik
0cd242315b Add live-python mode to python layer as extension 2016-01-31 21:47:18 +01:00
Christoph Paulik
f50859ab97 Revert "Set global pyenv version if no .python-version file exists"
This reverts commit bddf9de8f1.

When pyenv-auto-set-local-pyenv-version is set to 'on-visit then this
switched the python version when e.g. using jump to definition.
2016-01-26 01:21:02 -05:00
Christoph Paulik
0057df5cf5 Only load pyenv if it is installed
fix #4779
2016-01-24 14:42:59 +01:00
Christoph Paulik
bddf9de8f1 Set global pyenv version if no .python-version file exists 2016-01-23 17:09:52 +01:00
Eivind Fonn
0f5d576ada Re-add py-yapf 2016-01-23 15:00:23 +01:00
syl20bnr
33ead6fc42 Deprecation of extensions and <pkg>-excluded-packages variables
As announced in previous releases, see CHANGELOG.next for more info
in the Breaking Changes section.
2016-01-17 22:06:04 -05:00
syl20bnr
046d86800c Clean copyrights and update for year 2016 2016-01-11 21:42:17 -05:00
Fredrik Bergroth
c302ae4e67 Properly read version in .python-version
Fixes #4514
2016-01-11 01:13:09 -05:00
justbur
b0ee301845 layers: Conditionally load helm packages
Only use them when the spacemacs-helm layer is used.
2016-01-09 13:36:03 -05:00
syl20bnr
ae64d5b955 python: sort key bindings 2016-01-08 22:37:35 -05:00
Christoph Paulik
d4dfb385e7 Improve Python virtual environment docs and keybindings
Inspired by the discussion in
https://github.com/syl20bnr/spacemacs/issues/2841 I thought it was
useful to improve the Documentation and provide keybindings for all the
useful `pyvenv` functions.
2016-01-08 21:04:28 +01:00
syl20bnr
cddf18ff1e Update install layer section in REAMDE.org files 2016-01-06 00:21:55 -05:00
syl20bnr
db5901b3be python: Remove call to dash -when-let
Plus remove unnecessary defer t
2015-12-19 22:33:24 -05:00
Fredrik Bergroth
577e7b2d86 Auto-activate local pyenv version 2015-12-19 22:30:07 -05:00
Eivind Fonn
ac0ba50154 Make flycheck/flyspell hooks more explicit 2015-12-11 02:08:55 -05:00
hyh
979867447e Fix makefile for python version 2.7.10 2015-12-03 23:59:15 -05:00
Eivind Fonn
c893383fe4 Fix some documentation bugs
- CSS links
- GIFS in published version
- Unify layer doc titles
- Change emoji layer emojis to an image
2015-12-03 23:50:29 -05:00
Fabien Dubosson
3a5c375c6c Correct forgotten python major mode bindings 2015-11-22 18:45:12 +01:00
justbur
9befd20a1a layers: Transition to new key bindings functions
Removes dependence on evil-leader centralizing control over the method
of key binding in core-keybindings.el
2015-11-21 18:22:51 +01:00
Eivind Fonn
e7fbc84ff0 Remove package guards for evilified
See discussion in #3879
2015-11-21 11:07:14 +01:00
justbur
b294461957 evilified-state: Make into local package 2015-11-18 23:35:01 -05:00
Wieland Hoffmann
602a21beb9 python: list the correct keybindings for interacting with pyenv 2015-11-16 12:39:16 +01:00
Eivind Fonn
38e48aa95d Highlight TODO keywords in all prog modes
Also make the colon optional
2015-11-14 00:34:05 -05:00
Eivind Fonn
c3866382b2 Documentation update
- Add #+HTML_HEAD_EXTRA options to all org files
- HTMLize published documentation via CSS
2015-11-13 14:23:13 +01:00
Eivind Fonn
13c5b1d24b Convert documentation to publishable format 2015-11-01 23:40:29 -05:00
Diego Berrocal
358b38cec5 Add python prefixes for python 2015-10-29 19:29:46 +01:00
Wieland Hoffmann
104a1f8c9b Python: None of the keys start with m T, remove mention of it 2015-10-29 13:48:46 +01:00
Wieland Hoffmann
70ecefe79b python/doc: Fix a link to pylookup 2015-10-19 00:29:49 -04:00
Eivind Fonn
56ecd43753 Add variables to opt-in to flycheck/flyspell 2015-10-10 23:18:46 -04:00
Swaroop C H
0a6c619194 [python] Allow user to customize fill column 2015-10-07 15:51:40 -04:00
person808
c1b6293268 Replace eval-after-load with with-eval-after-load.
We now backport the macro for 24.3 so we can use it everywhere.
2015-10-07 15:51:39 -04:00
Eivind Fonn
c1561eadb7 Fix pylookup
- Set executable bit on pylookup.py
- Add update functions to autoload
- Document use of update functions
- Fix path setup
2015-10-07 15:51:39 -04:00
person808
706185b771 Simplify setting anaconda-mode server directory.
There is now a built-in variable we can use to customize the directory.
2015-09-23 23:32:02 -04:00
Alexandr Skurikhin
4eb83f2079 python-mode: fix py-yapf for yapf >= 0.3.0
yapf >= 0.3.0 now returns 2 if source code was changed.
2015-09-23 23:11:04 -04:00
Robert O'Connor
24c642ff3d Add back and fix evil-matchit for python-mode 2015-09-23 23:09:08 -04:00
syl20bnr
c505fde5e4 python: put anaconda-mode dir in cache dir 2015-09-22 19:28:53 -04:00
Robert O'Connor
3839e1a925 Temporarily disable evil-matchit for python.
See #3068; redguardtoo/evil-matchit#18 and redguardtoo/evil-matchit#58
2015-09-19 01:02:22 -04:00
Eivind Fonn
4f95d58bd4 Fix evil-matchit for python and ruby 2015-09-14 12:05:13 +02:00
Robert O'Connor
08ce016d63 add evil-matchit support for python 2015-09-14 12:03:30 +02:00
justbur
6eab954afe Use + instead of ! for layer categories
Helm seems to treat "!" specially in pattern matching, so having a ! in
the pattern string when traversing directories is problematic. This
change fixes #2737, because as far as I can tell "+" has no special
meaning in a helm pattern.

Of course, we can choose a different character, but I'm fond of "+" as
representing "more layers here".
2015-09-11 00:13:51 -04:00