Commit graph

1416 commits

Author SHA1 Message Date
Nathaniel Nicandro
f7df9cb9cf Allow table results to be suppressed by ":results scalar" 2019-02-22 08:29:00 -06:00
UndeadKernel
92d1d661c9 feature: Specify mime precedence using ":display" in org source blocks (#17)
A BEGIN_SRC block can specify which mime type to display by enabling the
user to manually set the priority order of mime types.

e.g.: In the following, :text/plain will be used before considering :text/html
#+BEGIN_SRC jupyter-python :display plain html
2019-02-22 07:56:22 -06:00
Nathaniel Nicandro
9484735c06
Fix undo in the REPL
When inserting continuation prompts, extra text deletion entries where being
added in `buffer-undo-list` which caused yanked text to not be undone fully
since it would add in those entries before undoing the yank.
2019-02-21 23:21:22 -06:00
Nathaniel Nicandro
e357166371
Add jupyter-org-insert-element 2019-02-21 17:14:59 -06:00
Nathaniel Nicandro
d927d3d58d
Test against the newest version of org-mode 2019-02-21 17:14:59 -06:00
Nathaniel Nicandro
70f4b1b9a3
jupyter-org--append-stream-result: Consider org-edit-src-content-indentation 2019-02-21 17:14:59 -06:00
Nathaniel Nicandro
7d72673604
Account for changes in org-mode 9.2
See #36. There were some assumptions being made on how `org-mode` interpreted
`fixed-width` elements which were changes in `org-mode` 9.2.
2019-02-21 17:14:59 -06:00
Nathaniel Nicandro
b1af59cbf3
jupyter-org--stream-context-p: Consider an empty drawer 2019-02-21 08:14:09 -06:00
Nathaniel Nicandro
de289fc90b
jupyter-org--add-result: Better doc string 2019-02-20 18:42:09 -06:00
Nathaniel Nicandro
ea5ae74c1d
Don't rely on temporarily clearing :file header argument
Attempt at #16.
2019-02-20 13:34:10 -06:00
Nathaniel Nicandro
67a1d9ee1d
jupyter--start-kernel: Use de-structuring in loop body 2019-02-19 10:03:03 -06:00
Nathaniel Nicandro
b5bae296b8
Also update Version header in test files 2019-02-19 09:45:55 -06:00
Nathaniel Nicandro
39fdac90dd
jupyter-org-client.el: Remove unused function declarations 2019-02-19 09:38:30 -06:00
Nathaniel Nicandro
10b1766035
jupyter-org-sync-results: Use when-let* 2019-02-19 09:33:58 -06:00
Nathaniel Nicandro
19e18f36f8
jupyter-repl-syntax-propertize-function: Fix bounds used 2019-02-19 02:58:55 -06:00
Nathaniel Nicandro
6d59862b4d
Remove redundant with-syntax-table 2019-02-18 11:31:57 -06:00
Nathaniel Nicandro
183547403d
jupyter-repl-ret: Use cond 2019-02-18 11:31:57 -06:00
Nathaniel Nicandro
76315d74bd
Fix byte compile error 2019-02-18 11:31:57 -06:00
Nathaniel Nicandro
1a184403a4
Update test 2019-02-17 23:41:01 -06:00
Nathaniel Nicandro
3f76534121 jupyter-repl-syntax-propertize-function: Consider string syntax in output 2019-02-17 23:07:00 -06:00
Nathaniel Nicandro
484b0934a3 Fix typos 2019-02-17 23:06:00 -06:00
Nathaniel Nicandro
4c7d7b390b jupyter-org-client.el: More refactoring 2019-02-17 23:05:00 -06:00
Nathaniel Nicandro
2119f29def jupyter-tunnel-connection: Use pcase-let to reduce verbosity 2019-02-17 23:04:00 -06:00
Nathaniel Nicandro
bad068f15b
jupyter--display-eval-result: Prefer markdown if available
If both plain text and markdown are provided, use markdown. IJulia provides
both representations when, e.g. asking for help on a symbol using ? at the
REPL.
2019-02-17 12:45:26 -06:00
Nathaniel Nicandro
249a088e2e
jupyter-handle-input-request: Be more secure when reading passwords 2019-02-17 12:19:16 -06:00
Nathaniel Nicandro
298138912d
Remove X-URL header from some files 2019-02-17 08:35:06 -06:00
Nathaniel Nicandro
4cbc5dcc55
jupyter-channel-ioloop.el: Remove unnecessary eval-and-compile 2019-02-17 08:28:17 -06:00
Nathaniel Nicandro
7d7307865b
CHANEGLOG.org -> CHANGELOG.org 2019-02-17 08:25:29 -06:00
Nathaniel Nicandro
7122b239e0
Move org-mode test setup functions to test/test-helper.el 2019-02-16 15:30:05 -06:00
Nathaniel Nicandro
0579dbcd97
jupyter-insert-latex: Remove modification-hooks from overlays
The modification-hooks added by `org-format-latex` cause the overlay to be
deleted whenever it is modified and this will also happen during text property
changes which we want to avoid. Since the buffer is read-only anyways, there is
no need for this hook.
2019-02-16 11:27:44 -06:00
Nathaniel Nicandro
87f1acbf86
jupyter-read-expression: Show the language when prompting 2019-02-16 11:27:44 -06:00
Nathaniel Nicandro
57eeb3dd52
Add tests for jupyter-with-display-buffer 2019-02-16 11:27:44 -06:00
Nathaniel Nicandro
0b6e032063
jupyter-with-display-buffer: Properly handle a nil RESET 2019-02-16 11:27:44 -06:00
Nathaniel Nicandro
afaf45fdea
jupyter-org-client.el: Refactor 2019-02-16 11:27:44 -06:00
Nathaniel Nicandro
2c8ccf32d6
jupyter-repl-kill-buffer-query-function: Ask to also kill the kernel 2019-02-16 09:45:46 -06:00
Nathaniel Nicandro
d8cb82f510
jupyter-with-display-buffer: Advance jupyter-display-buffer-marker
This removes any dependency on where `point` ends up when evaluating BODY.
2019-02-16 09:45:46 -06:00
Nathaniel Nicandro
6c7ceb4ae2
jupyter-completion-prefix (julia): Allow symbol key completion in dictionaries 2019-02-15 00:03:14 -06:00
Nathaniel Nicandro
67befbc10c
jupyter-channel-alive-p: Handle an invalid ioloop process 2019-02-14 23:48:51 -06:00
Nathaniel Nicandro
fafdf0d1b2 jupyter-code-context (completion): Larger context inside nested parens 2019-02-14 23:07:00 -06:00
Nathaniel Nicandro
1109681475 Add tests for jupyter-repl-syntax-propertize-function 2019-02-14 23:06:00 -06:00
Nathaniel Nicandro
d4969cbfcc CHANGELOG.org: Add function to change version numbers 2019-02-14 23:05:00 -06:00
Nathaniel Nicandro
b01764d06a jupyter-org-with-src-block-client: Avoid with-current-buffer
`jupyter-org-with-src-block-client` is used in the `completion-at-point`
interface and `with-current-buffer` is slow so there should be a slight speed
up here.
2019-02-14 23:04:00 -06:00
Nathaniel Nicandro
46fd8bec20
Generalize org-babel-jupyter-setup-export 2019-02-14 16:54:33 -06:00
Nathaniel Nicandro
75f9df7d0a
jupyter-repl-history-add-input -> jupyter-repl-history-add 2019-02-14 16:42:12 -06:00
Nathaniel Nicandro
913af5c314
Add jupyter-repl-cell-(pre|post)-send-hook 2019-02-14 16:42:12 -06:00
Nathaniel Nicandro
143eacc6fc
jupyter-repl-finalize-cell: Go to point-max first
The "current input cell" is intended to be the last cell in the REPL buffer so
go to `point-max` before calling `jupyter-repl-cell-beginning-position`.
2019-02-14 16:42:12 -06:00
Nathaniel Nicandro
6eec94a97f Integrate better with font-lock and syntax-ppss in the REPL buffer
* Add `jupyter-repl-syntax-propertize-function`. This allows packages like
  `rainbow-delimiters-mode` to work regardless of what is printed as output of
  a REPL cell by setting the syntax-table property on parenthesis in REPL
  output.

* Fix an issue with the Julia REPL which would cause `syntax-ppss` to
  report the wrong parenthesis depth due to the `]` character of the REPL
  package mode. Thus interfering with how `rainbow-delimiters-mode` works.

* Ensure that the kernel language's syntax table is used when fontifying and
  adding syntax properties.
2019-02-14 16:12:00 -06:00
Nathaniel Nicandro
32d886cf7e jupyter-eval-string: Better validation of jupyter-current-client 2019-02-14 16:11:00 -06:00
Nathaniel Nicandro
d0ccb98ae5
jupyter-repl-update-cell-count: Only reset input prompts
There is no need to reset the prompt when it isn't displaying the cell count.
This also ensures that a kernel that shows a prompt other than the input prompt
doesn't get overwritten.
2019-02-14 00:49:16 -06:00
Nathaniel Nicandro
098d5985f4
jupyter-run-repl: Better error if kernelspec can't be found 2019-02-14 00:11:31 -06:00