Search code examples
awesome-wm

How can I retrieve user input using awesome wm?


I'd like to retrieve a string from the user using awesome. I'll use this string to dynamically create a new tag. I just need some function that I can call that will take input from the keyboard and return the text that was typed in.


Solution

  • Something like this should help you get started:

    awful.prompt.run({ prompt = "Magic: " },
        mypromptbox[mouse.screen].widget, function(text)
            naughty.notify({ text = "you entered: " .. text })
        end))