Commit Graph

85 Commits

Author SHA1 Message Date
516d8dfbf8 pass node around instead 2021-04-11 17:10:57 +08:00
866368bfee convert info to plist 2021-04-11 16:32:59 +08:00
1c831dcd73 fix indents 2021-04-11 15:18:30 +08:00
3a2df140cb update conversion to accept template overrides
rename org-roam-capture--capture to org-roam-capture-
2021-04-11 15:05:22 +08:00
6f233363c8 fix indents 2021-04-10 00:34:43 +08:00
09b0d74359 add ref 2021-04-10 00:32:55 +08:00
1b1d2b2b76 [?] add ref...? 2021-04-09 22:35:01 +08:00
9a6cfe56c4 fix lint 2021-04-09 18:49:17 +08:00
45546ff6fa fix some lints 2021-04-09 18:15:45 +08:00
7a6b885b99 [breaking] update org-roam capture-template syntax 2021-04-09 15:54:26 +08:00
39bb939dc2 remove org-roam-capture--context 2021-04-09 14:16:01 +08:00
467b165678 fix org-roam-capture 2021-04-08 22:30:28 +08:00
d641ad4792 fix 2021-04-07 23:14:47 +08:00
18083cc1ed fix lint 2021-04-07 10:48:34 +08:00
5b0078e79d fix lints 2021-04-07 10:14:40 +08:00
5a3363ac22 fix lints 2021-04-07 10:09:46 +08:00
18aa3ac787 implement correct fix for org-roam-dailies 2021-04-07 10:01:33 +08:00
7a493d8549 [V2] make org-roam-dailies-xxx work 2021-04-07 09:54:05 +08:00
73a04a611a simplify: remove more unused things 2021-04-05 12:14:58 +08:00
ca1080b349 simplify: remove unused things 2021-04-03 21:26:18 +08:00
4e5a21d7e3 (breaking): simplify org-roam-capture
:file-name to contain extension. Specify ~.org.gpg~ to default to
encrypted, or ~.md~, if you wish to not use Org-mode...
2021-04-03 20:05:23 +08:00
fb27fc78bc org-roam-capture: refactor 2021-04-02 21:18:40 +08:00
a35b0e7c6d org-roam-capture: cleanup capture calls 2021-04-02 20:10:04 +08:00
490901957e fix some byte-compile errors 2021-03-29 00:34:30 +08:00
f681c51630 fix 2021-03-28 23:58:43 +08:00
315e2dc447 fix lints 2021-03-24 14:24:40 +08:00
6fae3aa74c fix capture 2021-03-19 11:20:19 +08:00
53dcf687ef org-roam v2 2021-03-19 11:20:18 +08:00
06e5814898 (fix): org-roam-dailies: fix false warning on new file (#1387)
Fixes #1358
2021-01-16 21:06:50 +08:00
05a9bc44f2 (fix): fix org-roam-capture--get-point (#1376) 2021-01-11 19:38:02 +08:00
3fb4e21adf (fix): fix org-roam-protocol--open-ref creating new files (#1375)
We need to split the ref into its type/file before querying the db for a
match. Throw a warning when `org-roam--capture-new-file` tries to
recreate an existing file.
2021-01-10 23:05:45 +08:00
48e195dd82 (refactor): refactor org-roam-capture (#1355) 2020-12-22 21:57:02 +08:00
43831c5819 (fix): allow link captures (#1347)
Previously we had set `org-capture-link-is-already-stored` to `t` in
org-roam captures, because org-roam-protocol stores links. This
prevented regular captures from utilizing the %a element in the
templates.

Instead, only set `org-capture-link-is-already-stored` in the
org-roam-protocol capture command.

Fixes #1341.
2020-12-16 21:12:21 +08:00
06d0db736a (internal): remove error-checking for olp (#1326)
The `org-roam-capture-find-or-create-olp` function will throw the same
error, so we don't have to explicitly catch and throw.
2020-11-24 21:09:28 +08:00
b1608bf869 (feat): capture: create OLP if does not exist (#1270)
Remove the requirement that the OLP already exists in the captured file.
Also, make OLP available beyond dailies functionality.
2020-11-13 16:29:00 +08:00
cc01cf346e (release): v1.2.3 (#1269) 2020-11-13 14:22:18 +08:00
023bcce867 (internal): remove unnecessary variables (#1244)
For captures, enforce that `:file-name` needs to be specified, and
`:head` when not provided defaults to the empty string (i.e. no head)
2020-11-10 23:58:16 +08:00
4f6eb285bf (feat): Overhaul org-roam-dailies (#978)
Implement ideas from `org-journal` to `org-roam-dailies`.

Update the doc.
2020-11-10 14:31:38 +01:00
7602b8c48d (feat): Allow ORP to capture the webpage's selection (#1239)
* (feat): Temporarily store link when capturing with ORP

* org-roam-protocol.el (org-roam-protocol-open-ref): Replicate default
`org-protocol' behaviour temporarily for storing links
* org-roam-capture.el (org-roam-capture--capture): Prevent stored link from
being reset

When capturing a web-page with org-roam-protocol, a link is now temporarily
stored in `org-store-link-plist' via `org-link-store-props'.  This is to allow
the forwarding of properties to `org-capture', one of them being `:initial'
which contains the content of the selected text in the browser.

* (feat): Add toggle for storing link when capturing with ORP

* org-roam-protocol.el (org-roam-protocol-store-links): Add new toggle
(org-roam-protocol-open-ref): Conditionally store link for later used

Building up on b2ee5f2c68, the user can now
decide whether to store links when capturing with org-roam-protocol (default
nil).

* Update changelog
2020-11-08 13:30:16 +01:00
0cce9d1165 (release): Org-roam v1.2.2 (#1168) 2020-10-06 03:02:41 +08:00
d973e8f6e0 (feat): support file-level IDs (#1163)
Additionally cache IDs at outline-level 0, now that property drawers are supported in Org 9.4.

Update org-roam--format-link to prefer ID links wherever possible. That is, when a file has an ID, use an id link instead of file link.
2020-10-05 16:57:54 +08:00
668f135aa1 (internal): remove file-name and header default (#1143) 2020-09-27 04:29:10 +08:00
e881ea26b1 (internal): bump required version of emacsql-sqlite3 to 1.0.2 (#1102)
This version includes the fix that ignores the user .sqliterc which can
interfere with expected behaviour.

See https://github.com/cireu/emacsql-sqlite3/pull/15 for more details.
2020-09-15 15:10:36 +08:00
30b2e97426 (feat): add org-capture interactive options to org-roam-capture (#1035) 2020-08-16 19:51:37 +08:00
0318983cac (feat): cache all link-types (#1009)
Co-authored-by: Jethro Kuan <jethrokuan95@gmail.com>
2020-08-10 15:59:02 +08:00
6345d0c22e (feat): Protect region targeted by org-roam-insert (#974)
Co-authored-by: Jethro Kuan <jethrokuan95@gmail.com>
2020-07-27 20:16:39 +02:00
f2c1500beb (doc): Fix docstring (#979) 2020-07-27 11:43:23 +02:00
89e9121f26 (release): Org-roam v1.2.1 (#975) 2020-07-27 01:03:35 +08:00
20f876aa6b (feat): enable nested captures (#966)
This PR enables the long-awaited nested-captures.

1. Adds a hook to org-capture-prepare-finalize-hook, which installs org-roam-capture--finalize into org-capture-after-finalize-hook if the capture is an Org-roam capture. This function contains key functionality for Org-roam to Do The Right Thing after specific interactive functions, such as finding the file, or inserting a link.

2. A patch for org-capture-finalize. Specifically, we make org-capture-plist valid during org-capture-finalize.

3. Many hacks that were originally in place are now replaced with nicer alternatives.

Co-authored-by: Leo Vivier <zaephon@gmail.com>
2020-07-27 00:21:41 +08:00
863ae2427e (feat): add customize settings for capture templates (#968)
adds ability to customize capture templates using the Customize interface for:

1. org-roam-capture-ref-templates
2. org-roam-dailies-capture-templates
3. org-roam-capture-immediate-template
2020-07-26 15:15:56 +08:00