-
Notifications
You must be signed in to change notification settings - Fork 209
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Commands in notes won't execute unless under a > heading #167
Comments
If you're in bash or zsh, type "foo" at the prompt, and then type Ctrl+G
(instead of ''Ctrl+X"). That will go straight to the note file, whether it
has headings or not.
…--Craig
On Fri, Mar 3, 2017 at 8:58 AM, Brian Zwahr ***@***.***> wrote:
I have a xiki note in which I have some shell commands for easy access. At
the top of the note, I have a "heading", starting with >. With this note,
I can run commands like this:
$ fooCTRL-X # to get into the note
CTRL-O # to open the heading
<type to search/filter>
CTRL-G # to run the command the cursor is on
I realized that I could save a step by removing the header. Then I
wouldn't need that first CTRL-O in the process. I could just open the note
file and immediately start searching. (With headings, immediately searching
searches for matching headings only.)
However, if I remove the > heading, the note doesn't work properly. I can
immediately search for the right command, but pressing CTRL-G on the
command doesn't do anything.
Are shell commands within notes required to be under a > heading in order
to be executed?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#167>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AAAsWy0f9tOwtIotnsnGWTNhKOH8HPT8ks5riEbLgaJpZM4MSf3e>
.
|
Ah, ok. So that's an option that keeps me from having to Ctrl-O to open the headings to see their contents. However, I can't search/filter in the note edit view, unfortunately. Understandably so, though. I guess as is, Xiki doesn't quite do exactly what I want. I'm curious, though: why, if I remove the heading line, does Ctrl-G not execute commands from the note file when it's opened with Ctrl-X?
|
The practical answer is ^O runs commands when the line is like " $ foo".
When you ^X, it shows them as " : $ foo". (It quotes the whole file with
":" so the lines won't interact).
A temporary fix would be for you to manually delete the ": " before the
command after you ^X.
But I think you're convincing me that shell commands should be exposed
(unquoted) by default in that particular context. I've never really used
notes without headings. But I can see how doing so so you can filter the
whole file and then run commands would be useful.
…--Craig
On Fri, Mar 3, 2017 at 6:03 PM Brian Zwahr ***@***.***> wrote:
Ah, ok. So that's an option that keeps me from having to Ctrl-O to open
the headings to see their contents. However, I can't search/filter in the
note edit view, unfortunately. Understandably so, though. I guess as is,
Xiki doesn't quite do exactly what I want.
I'm curious, though: why, if I remove the heading line, does Ctrl-G not
execute commands from the note file when it's opened with Ctrl-X?
- If you open the note with Ctrl-G (note "edit mode", I guess), Ctrl-G
executes commands regardless of headings. (But the text obviously doesn't
search/filter)
- If you open the note with Ctrl-X and the commands are under a
heading, Ctrl-G executes. (Once you open the heading and manually move to
the proper command.)
- If you open the note with Ctrl-X and the commands are *not* under a
heading, Ctrl-G doesn't execute the commands. Why not?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#167 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAAsW6rWqI0O3xJ0UxBFOVAQY_Go9vLWks5riMZ_gaJpZM4MSf3e>
.
|
Oh, I didn't notice the difference with the colon. I'll watch for that. I'm glad you seem to understand my use case, though! Hopefully that's something you can account for. If not, I can still do what I need to do, just less conveniently. :-) |
Yes, I'll add it. Please keep this issue open to remind me. And don't
hesitate to ping me again in a few days if it's something that's urgent for
you. I'm currently working on the video for my next kick starter for Xiki,
but will try to get to it after that.
…--Craig
On Sun, Mar 5, 2017 at 10:11 AM Brian Zwahr ***@***.***> wrote:
Oh, I didn't notice the difference with the colon. I'll watch for that.
I'm glad you seem to understand my use case, though! Hopefully that's
something you can account for. If not, I can still do what I need to do,
just less conveniently. :-)
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#167 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAAsW6u3Bz2ZnBeX9nNrXS8_7rttgD3Fks5rivrLgaJpZM4MSf3e>
.
|
Not urgent, but nice to have. I'm still learning Xiki and in the "trying it out" stage, so it's not exactly an integral part of my workflow, yet. I'd love to see a new video showcasing the newer Xiki, though! It has changed a lot since I first tried it, back when it had to be run within Emacs, I think? :) |
I have a xiki note in which I have some shell commands for easy access. At the top of the note, I have a "heading", starting with
>
. With this note, I can run commands like this:I realized that I could save a step by removing the header. Then I wouldn't need that first CTRL-O in the process. I could just open the note file and immediately start searching. (With headings, immediately searching searches for matching headings only.)
However, if I remove the
>
heading, the note doesn't work properly. I can immediately search for the right command, but pressing CTRL-G on the command doesn't do anything.Are shell commands within notes required to be under a
>
heading in order to be executed?The text was updated successfully, but these errors were encountered: