You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Original issue: #227
Extending conversation from #228
From the original issue, there was an problem with the initial-input for completing-read. After testing a few things, an issue with the org-ql-view--complete-buffers-files not supporting multiple files when trying to refresh org-ql-view was found. Consequently the use of completing-read-multiple was proposed in #228.
The refactor of the org-ql-view--complete-buffers-files entails the following:
Use completing-read-multiple in org-ql-view--complete-buffers-files
Refactor org-ql-view--contract-buffers-files to allow displaying buffers-or-files in the view buffer
All file names and buffers/buffer-names are normalized to allow identifying duplicates.
When a list is passed, if it's not one of the special cases (eg: "org-directory"), make sure it's a list of strings.
Remove duplicate entries if there are any (in theory this should never happen?)
If the value being contracted is a function and it resolves to the org-agenda-files function, contract to "org-agenda-files" instead of a function.
Expect the output of this function to be a list of strings, a string value, or a function.
Refactor org-ql-view--expand-buffers-files to always return a list of string to allow displaying them in the view buffer
Resolve all values to a list of strings and ensure no unique values are present in them.
Refactoring org-ql-view--expand-buffers-files will impact org-ql-view--link-follow in the following ways:
There is no need to test if the values returned by org-ql-view--expand-buffers-files is a buffer or string at
so one can add another list to it, either by providing a function or by an explicit list. From my experiments it is not as trivial as simply refactoring the variable.
We tried to solve it in #228 , didn't have the time to finish that. There were a few issues we hand't ironed out. I can revisit this when I have some time.
Original issue: #227
Extending conversation from #228
From the original issue, there was an problem with the
initial-input
forcompleting-read
. After testing a few things, an issue with theorg-ql-view--complete-buffers-files
not supporting multiple files when trying to refreshorg-ql-view
was found. Consequently the use ofcompleting-read-multiple
was proposed in #228.The refactor of the
org-ql-view--complete-buffers-files
entails the following:completing-read-multiple
inorg-ql-view--complete-buffers-files
org-ql-view--contract-buffers-files
to allow displayingbuffers-or-files
in the view bufferorg-agenda-files
function, contract to "org-agenda-files" instead of a function.org-ql-view--expand-buffers-files
to always return a list of string to allow displaying them in the view bufferorg-ql-view--expand-buffers-files
will impactorg-ql-view--link-follow
in the following ways:org-ql-view--expand-buffers-files
is a buffer or string atorg-ql/org-ql-view.el
Line 636 in 31aeb0a
This will reflect in the test cases as well
The text was updated successfully, but these errors were encountered: