Commit Graph

155 Commits

Author SHA1 Message Date
7e02cbb17d lang/python: add miniconda3 path 2018-11-14 22:33:18 -08:00
80e53eee5d lang/python: add homebrew miniconda3 path
For `brew cask install miniconda`
2018-11-15 00:55:54 -05:00
ba93402dcc lang/python: fix typo in +python-version
Thanks to @ztlevi
2018-10-07 00:46:50 -04:00
d21887149f Minor refactor/reformatting 2018-10-06 20:44:25 -04:00
9185da824c lang/python: remove +ipython flag
+ Replace +ipython functionality with +python/open-ipython-repl command.
+ Use python-shell-interpreter for eval handlers, repl and python
  version detection.
+ Removed various python-shell-* variables for ipython; they are already
  supported upstream.
2018-10-06 20:44:25 -04:00
7c6e2e705f lang/python: add Ipython/Jupyter REPL commands 2018-10-06 20:44:25 -04:00
7f1b526f64 Set python-shell-* vars early
To make it easier for users to overwrite them in thir config.el (without
an after! block).
2018-10-03 00:05:45 -04:00
63b195b133 lang/python: fix stringp errors when opening REPL
Caused my misuse of if-let* to let-bind dynamic variables. The expanded
code doesn't quite work out the way I expected, causing
python-shell-interpreter to be nil regardless of which side of the
if-else statement ran.
2018-10-02 23:52:29 -04:00
53fe7a1f04 Refactor Project API to reflect changes upstream
projectile-project-root no longer returns `default-directory` if not in
a project (it returns nil). As such, doom-project-* functions (and their
uses) have been refactored.

+ doom-project-p & doom-project-root are aliases for
  projectile-project-p & projectile-project-root.
+ doom-project-{p,root,name,expand} now has a DIR argument (for
  consistency, since projectile-project-name and
  projectile-project-expand do not).
+ The nocache parameter is no longer necessary, as projectile's caching
  behavior is now more sane.
+ Removed some projectile advice/hacks that are no longer necessary.
+ Updated unit tests
2018-09-28 21:13:27 -04:00
431ea613b0 lang/python: set PIPENV_MAX_DEPTH in eval handler
Instead of changing the cwd, which chould have other reprecussions for
the code about to be executed.
2018-09-26 20:38:02 -04:00
da55ee2af2 lang/python: fix pipenv support for +python/repl 2018-09-26 20:37:35 -04:00
68699c3d5b lang/python: make repl/eval handlers respect pipenv 2018-09-26 12:28:32 -04:00
4e0a4e1b51 lang/{ruby,python}: Fix advice arguments errors 2018-09-26 09:57:10 -04:00
b91a8f0d2f lang/python: rewrite modeline version segment
+ Add $PYENV_ROOT/shims was added to exec-path, so pyenv python version
  is picked up on.
+ Fixes out-of-date python version in the modeline of other buffers
  after switching pyenv/pyvenv/conda envs.
+ The pipenv version and regular python display have been merged.
2018-09-25 22:17:41 -04:00
ccaa642d98 lang/python: fix pipenv creating Pipfiles in pwd #888
`pipenv run ...` searches for a Pipfile itself, but doesn't search far
enough, creating a Pipfile in the current directory. Instead, we run the
command from the pipenv project root so it doesn't have to search.
2018-09-21 13:33:19 -04:00
5145e7e822 lang/python: tab-width = python-indent-offset #882
This fixes evil-shift-width too (which is set to tab-width by
evil-collection-python).
2018-09-13 19:15:15 -04:00
c58077810d General refactor of modules
General code and comment improvements.

Also, removed the :desc's for csv-mode because map! is currently unable
to set which-key descriptions mode-locally, and should be avoided for
anything but global keybinds. This will be fixed when General is
introduced into Doom.
2018-09-09 09:58:20 -04:00
7d3ffdff06 Remove third line in section headers
This is truly important stuff. We've saved many lives with this update.
2018-09-09 09:58:19 -04:00
45e22c7e23 add anaconda3 home path '/usr/local/anaconda3' 2018-09-09 17:18:39 +08:00
69e992e54a lang/python: minor reformatting 2018-08-12 02:46:55 +02:00
69eb2cd40d lang/python: improve pipenv support 2018-08-11 21:18:21 +02:00
552b8b50c0 lang/python: pyvenv-mode -> pyvenv #777
Fixed incorrect package name.
2018-08-04 16:34:01 +02:00
a18541851e lang/python/doctor: check pyenv, conda & ipython 2018-08-02 00:13:00 +02:00
9b11f8e76d lang/python: remove +python-conda-env (unused) 2018-08-01 22:32:29 +02:00
7ffa3c8d8d lang/python: register ANACONDA_HOME envvar 2018-08-01 22:30:30 +02:00
e053234992 lang/python: fix anaconda ignoring conda envs 2018-08-01 22:29:51 +02:00
ad68f26477 Fix python mode-line persisting into other modes
And more polish for the python mode-line indicator.
2018-08-01 15:17:57 +02:00
65f0dcef54 lang/python: remove references to removed variable 2018-08-01 01:31:12 +02:00
90d0f334f8 lang/python: rewrite mode-line indicator (again) 2018-08-01 01:13:49 +02:00
9cf5907c48 lang/python: update modeline on version change 2018-07-31 23:21:13 +02:00
991199ee78 Fix PYENV -> PYENV_ROOT envvar typo 2018-07-31 23:16:18 +02:00
b4c8584f64 lang/python: rewrite version mode-line segment 2018-07-31 23:07:22 +02:00
d9a52e1094 Fix company/lookup settings in anaconda-mode
Applying them to python-mode means it would happen too late.
2018-07-31 19:20:58 +02:00
560d16d651 lang/python: add support for more env managers
+ Rewritten +conda support
+ Adds +pyenv and +pyvenv flags with support.
+ New +ipython flag to enable ipython REPL support
+ Added pipenv support. This is the new default, instead of pyenv, and
  isn't hidden behind a module flag because it is officially endorsed by
  python.

Addresses #736
2018-07-31 15:51:25 +02:00
90d09e6f93 Highlight-numbers on every prog-mode 2018-07-29 12:19:56 +10:00
e8d4b74c29 lang/python: refactor conda integration
Removes the +python-conda-home variable and guesses conda-anaconda-home
at startup.
2018-07-17 22:07:35 +02:00
bb1171b64b lang/python/autoload.el -> autoload/python.el 2018-07-17 20:57:32 +02:00
0a577f3a0e lang/python: fix pyenv version detection #736 2018-07-06 23:56:50 +02:00
e05d7cfee0 Change flycheck initialization strategy
Initialize it globally and turn it off where needed, instead of enabling
it on demand. Also fixes void-function: flycheck-mode errors when
:feature syntax-checker is disabled. This is experimental.

Indirectly fixes #710
2018-06-22 01:49:20 +02:00
6808c46b58 💥 Change set-popup-rule! usage
Now accepts a flat plist of all its former parameters, including new
:parameters and :actions properties to increase your control over the
fate of your windows.

The old usage of set-popup-rule! is deprecated and may not work right!

The :ui popup module has also seen a major refactor to improve
efficiency and load times.

Sorry! This is the last "big" change before 2.1!
2018-06-18 02:34:16 +02:00
ec8ae0bedc Add :ui pretty-code & set-pretty-symbols! autodef
Along with defaults for C/C++, elm, elisp, js, typescript, web-mode, and
org-mode. Thanks to @ar1a for inspiration.
2018-06-16 19:32:25 +02:00
4d017ae19e Replace :yas-minor-mode with set-yas-minor-mode! 2018-06-15 18:03:50 +02:00
c0251aacee Replace :lookup with set-lookup-handlers! autodef
And update all internal references.
2018-06-15 17:27:48 +02:00
588359cc5f Replace :eval/:repl with autodef functions
+ :eval => set-eval-handler!
+ :repl => set-repl-handler!
+ Updates all internal references.
2018-06-15 16:20:20 +02:00
9f0ebe42e8 Replace :electric with set-electric-rules!
And general refactor of the emacs/electric-indent module.

Also updates (set! :electric ...) references in various :lang modules
2018-06-15 13:32:07 +02:00
98d2f1de3f Add set-env! autodef; make :env obsolete 2018-06-15 03:42:01 +02:00
d8b1e469bc Introduce autodefs to replace some settings
+ :popup -> set-popup-rule!
+ :popups -> set-popup-rules!
+ :company-backend -> set-company-backend!
+ :evil-state -> set-evil-initial-state!

I am slowly phasing out the setting system (def-setting! and set!),
starting with these.

What are autodefs? These are functions that are always defined, whether
or not their respective modules are enabled. However, when their modules
are disabled, they are replaced with macros that no-op and don't
waste time evaluating their arguments.

The old set! function will still work, for a while.
2018-06-15 03:42:01 +02:00
1d6d11e803 add meta doc 2018-06-07 01:12:03 +08:00
732c2979c4 Naming convention and add docs; Avoid conflicting pyenv. 2018-06-07 01:08:49 +08:00
fada449bd4 Get rid of a stray + 2018-06-05 18:02:46 -05:00