jarun / nnn

n³ The unorthodox terminal file manager
BSD 2-Clause "Simplified" License
18.51k stars 743 forks source link

Syntax error with prescribed split-pane script #1826

Closed slferris closed 3 months ago

slferris commented 4 months ago

Environment details (Put x in the checkbox along with the information)

Exact steps to reproduce the issue

I'm trying to create an "ewrap" script to enable split-pane feature in nnn. I copied it from your nnn repos, but when I try to create a script, I get a syntax error: Expected "," or "]" but found """. Here is the script as I copied it:

!/usr/bin/env sh

if [ -n "$TMUX" ] ; then

tmux session running

tmux split-window -h "vim \"$*\" "

else

Remove option --tab for new window

xfce4-terminal --tab -e "vim \"$*\" "

fi

N-R-K commented 4 months ago

get a syntax error: Expected "," or "]" but found """.

paste the full error message along with which line it triggers the error.

slferris commented 4 months ago

On Feb 23, 2024, at 7:22 AM, NRK @.***> wrote:

get a syntax error: Expected "," or "]" but found """.

paste the full error message along with which line it triggers the error.

— Reply to this email directly, view it on GitHub https://github.com/jarun/nnn/issues/1826#issuecomment-1961412565, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJRHVVMITW34KKJACQAWYNLYVCQZHAVCNFSM6AAAAABDP5RD3GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNRRGQYTENJWGU. You are receiving this because you authored the thread.

slferris commented 4 months ago

Here is the unobstructed view of the script.

On Feb 23, 2024, at 9:07 AM, Stephen Ferris @.***> wrote:

On Feb 23, 2024, at 7:22 AM, NRK @.***> wrote:

get a syntax error: Expected "," or "]" but found """.

paste the full error message along with which line it triggers the error.

— Reply to this email directly, view it on GitHub https://github.com/jarun/nnn/issues/1826#issuecomment-1961412565, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJRHVVMITW34KKJACQAWYNLYVCQZHAVCNFSM6AAAAABDP5RD3GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSNRRGQYTENJWGU. You are receiving this because you authored the thread.

slferris commented 4 months ago

I did finally get the detached window feature to work with tmux and vim. However, in the detached window or split-window, I am not able to edit the text document in vim. Is there a way to do that?

N-R-K commented 3 months ago

I am not able to edit the text document in vim

You need to actually start providing more info if you want any help. Just saying "doesn't work" provides zero information for us to try to figure out what might be going wrong.

And for the record, I can edit just fine with vim on the newly created tmux split.

slferris commented 3 months ago

Sorry I annoyed you. Thanks for your response.

On Mar 10, 2024, at 10:27 AM, NRK @.***> wrote:

I am not able to edit the text document in vim

You need to actually start providing more info if you want any help. Just saying "doesn't work" provides zero information for us to try to figure out what might be going wrong.

And for the record, I can edit just fine with vim on the newly created tmux split.

— Reply to this email directly, view it on GitHub https://github.com/jarun/nnn/issues/1826#issuecomment-1987285838, or unsubscribe https://github.com/notifications/unsubscribe-auth/AJRHVVMDFIKS4NLJ6EIQY33YXSCWNAVCNFSM6AAAAABDP5RD3GVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSOBXGI4DKOBTHA. You are receiving this because you authored the thread.

KlzXS commented 3 months ago

It's been 3 weeks and no new info.

Here is the unobstructed view of the script.

I can't even see what's posted here: image

I'm closing this and if you still have problems with this post full script and error messages and we'll revisit it.