Skip to content

Instantly share code, notes, and snippets.

@madprops

madprops/test.rb Secret

Created August 31, 2022 10:52
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save madprops/e7287c454b1b9900082b4eece9679cd3 to your computer and use it in GitHub Desktop.
Save madprops/e7287c454b1b9900082b4eece9679cd3 to your computer and use it in GitHub Desktop.
require "open3"
lines = "aaa\nbbb\nccc"
cmd = "rofi -dmenu"
stdin, stdout, stderr, wait_thr = Open3.popen3(cmd)
stdin.puts(lines)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment