Advertisement
mengyuxin

meng.bulletPointAdder.py

Dec 31st, 2017
305
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.34 KB | None | 0 0
  1. #! python3
  2. # bulletPointAdder.py - Adds Wikimedia bullet points to the start
  3. # o feach line of text on the clipboard.
  4.  
  5. import pyperclip
  6. text = pyperclip.paste()
  7.  
  8. # Separate lines and add stars.
  9. lines = text.split('\n')
  10.  
  11. for i in range(len(lines)):
  12.     lines[i] = '* ' + lines[i]
  13.    
  14. text = '\n'.join(lines)
  15. pyperclip.copy(text)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement