Skip to content

Commit

Permalink
Merge pull request #195 from daniel-shimon/powershell-noprofile
Browse files Browse the repository at this point in the history
Improve powershell speed with '-noprofile'
  • Loading branch information
asweigart authored Oct 12, 2021
2 parents e6e694f + dc13bff commit 781603e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/pyperclip/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -511,7 +511,8 @@ def copy_wsl(text):
p.communicate(input=text.encode(ENCODING))

def paste_wsl():
p = subprocess.Popen(['powershell.exe', '-command', 'Get-Clipboard'],
# '-noprofile' speeds up load time
p = subprocess.Popen(['powershell.exe', '-noprofile', '-command', 'Get-Clipboard'],
stdout=subprocess.PIPE,
stderr=subprocess.PIPE,
close_fds=True)
Expand Down

0 comments on commit 781603e

Please sign in to comment.