-
-
Save stevedev/3c68217024d81c37b833f0c89f75fb6f to your computer and use it in GitHub Desktop.
Fish tank generator for slack. Because.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
# some fish! | |
fish = %w{ fish fish2 fish3 fish4 fish5 fish6 fish7 } | |
# At least 3 lines | |
lines = rand(4) + 3 | |
output = "" | |
lines.times do | |
# At least 5 fish per line | |
fish_per_line = rand(6) + 5 | |
fish_per_line.times do | |
selected_fish = fish.sample | |
space = " " * (rand(7) + 3) | |
output << "#{space}:#{selected_fish}:" | |
end | |
output += "\n" | |
end | |
# write to pbcopy | |
IO.popen('pbcopy', 'w') do |pbcopy| | |
pbcopy << output | |
end |
What about plants? 🤔
And the coral emoji would be cool too
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Note... you'll need to add the fish emoticons for this to work.