Copy text to clipboard using pyperclip.
(text: str)
| 42 | |
| 43 | |
| 44 | def copy_to_clipboard(text: str) -> bool: |
| 45 | """Copy text to clipboard using pyperclip.""" |
| 46 | import pyperclip |
| 47 | |
| 48 | try: |
| 49 | pyperclip.copy(text) |
| 50 | return True |
| 51 | except pyperclip.PyperclipException: |
| 52 | return False |
| 53 | |
| 54 | |
| 55 | def validate_bot_name(name: str) -> tuple[bool, str]: |