Skip to content
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

Scrotter issue #22

Open
LeVraiArdox opened this issue Dec 27, 2023 · 0 comments
Open

Scrotter issue #22

LeVraiArdox opened this issue Dec 27, 2023 · 0 comments

Comments

@LeVraiArdox
Copy link

Hi there.
i replaced maim with scrot in you scrotter script. But idk why, only the "window" script seems to works.
The "selection" have a problem too: it works only one time on 10.
Is maim very important for the code ? Or am i just shitty ?
here is the snippet:

  local fullscreen = createButton('󰍹', 'Fullscreen', function()
    close()
    local name = getName()
    local cmd = "scrot " .. name
    awful.spawn.easy_async_with_shell(cmd, function()
      copyScrot(name)
    end)
  end, beautiful.green)

  local selection = createButton('󰩭', 'Selection', function()
    close()
    local name = getName()
    local cmd = "scrot -s " .. name
    awful.spawn.easy_async_with_shell(cmd, function()
      copyScrot(name)
    end)
  end, beautiful.blue)

  local window = createButton('󰘔', 'Window', function()
    close()
    local name = getName()
    local cmd = "scrot -u " .. name
    awful.spawn.easy_async_with_shell(cmd, function()
      copyScrot(name)
    end)
  end, beautiful.red)
local getName = function()
  local string = "~/Images/" .. os.date("%d-%m-%Y-%H:%M:%S") .. ".jpg"
  return string
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant