Replies: 1 comment 1 reply
-
The shell removes the single quotes `'`, try without them
…On Wed, 15 May 2024, 19:56 Pismice, ***@***.***> wrote:
Context:
I like to give names to my workspaces, so I often find myself typing this
type of "long" commands: /bin/i3-msg 'rename workspace "1" to "1:
internet"'
The problem with this is that I always have to rewrite the old name and
not forget to add again the "1: " in the new name.
So I write a small Zig app to do this for me: I would just pass the id of
the workspace I want to change and the new name I want. ex: ./my_app 4
docs, could change something from "4: blabla" to 4: docs"
Problem:
When executing my script I get this error:
ERROR: Your command: 'rename workspace "1: docs" to "1: docs"'
ERROR: ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
ERROR: Expected one of these tokens: <end>, '[', 'move', 'exec', 'exit', 'restart', 'reload', 'shmlog', 'debuglog', 'border', 'layout', 'append_layout', 'workspace', 'focus', 'kill', 'open', 'fullscreen', 'sticky', 'split', 'floating', 'mark', 'unmark', 'resize', 'rename', 'nop', 'scratchpad', 'swap', 'title_format', 'title_window_icon', 'mode', 'bar', 'gaps'
but when just copying pasting the same command:
/bin/i3-msg 'rename workspace "1: docs" to "1: docs"'
I get:
[{"success":true}]
What I tried:
Adding a \n at the end of my parameter in my Zig script
—
Reply to this email directly, view it on GitHub
<#6056>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABMCZPVZEVM3NJCU4U72NWLZCOOU3AVCNFSM6AAAAABHYUQLCCVHI2DSMVQWIX3LMV43ERDJONRXK43TNFXW4OZWGY3TGNJUGY>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
Pismice
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Context:
I like to give names to my workspaces, so I often find myself typing this type of "long" commands:
/bin/i3-msg 'rename workspace "1" to "1: internet"'
The problem with this is that I always have to rewrite the old name and not forget to add again the "1: " in the new name.
So I write a small Zig app to do this for me: I would just pass the id of the workspace I want to change and the new name I want. ex: ./my_app 4 docs, could change something from "4: blabla" to 4: docs"
Problem:
When executing my script I get this error:
but when just copying pasting the same command:
/bin/i3-msg 'rename workspace "1: docs" to "1: docs"'
I get:
[{"success":true}]
What I tried:
Adding a
\n
at the end of my parameter in my Zig scriptBeta Was this translation helpful? Give feedback.
All reactions