Advertisement
Guest User

Untitled

a guest
Jan 28th, 2020
217
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.60 KB | None | 0 0
  1. #! python3
  2. # mclip.py = A multi - clipboard program.
  3.  
  4. TEXT = {'agree': """ Yes, I agree. That sounds fine to me.""",
  5. 'busy': """Sorry, can we do this later this week or next week?""",
  6. 'upsell': """Would you consider making this a monthly donation?"""}
  7.  
  8. import sys, pyperclip
  9. if len(sys.argv) < 2:
  10. print('Usage: python mclip.py [keyphrase] - copy phrase text')
  11. sys.exit()
  12.  
  13. keyphrase = sys.argv[1]
  14.  
  15. if keyphrase in TEXT:
  16. pyperclip.copy(TEXT[keyphrase])
  17. print('Text for ' + keyphrase + 'copied to clipboard.')
  18. else:
  19. print('There is no text for ' + keyphrase)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement