summaryrefslogtreecommitdiff
path: root/coil_gen.py
diff options
context:
space:
mode:
authorjaseg <git@jaseg.de>2023-06-20 14:07:03 +0200
committerjaseg <git@jaseg.de>2023-06-20 14:07:03 +0200
commitd43308c5cc767d817ac8f77d38c6baf124de1b7c (patch)
tree727ea752962622d1d34b8c8c7e80c9bc6d9cb182 /coil_gen.py
parentc29802c2b941150b92720124aa2512da70aeff3b (diff)
downloadgerbonara-d43308c5cc767d817ac8f77d38c6baf124de1b7c.tar.gz
gerbonara-d43308c5cc767d817ac8f77d38c6baf124de1b7c.tar.bz2
gerbonara-d43308c5cc767d817ac8f77d38c6baf124de1b7c.zip
Add twisted coil gen
Diffstat (limited to 'coil_gen.py')
-rw-r--r--coil_gen.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/coil_gen.py b/coil_gen.py
index 0c8d5ca..896ec1b 100644
--- a/coil_gen.py
+++ b/coil_gen.py
@@ -304,8 +304,9 @@ def generate(infile, outfile, polygon, start_angle, windings, trace_width, clear
if clipboard:
try:
- print(f'Running {copy[0]}. Press Ctrl+C when you are done pasting.')
- subprocess.run(copy, capture_output=True, text=True, check=True, input=fp.serialize())
+ print(f'Running {copy[0]}.')
+ proc = subprocess.Popen(copy, stdin=subprocess.PIPE, text=True)
+ proc.communicate(fp.serialize())
except FileNotFoundError:
print(f'Error: --clipboard requires the {copy[0]} and {paste[0]} utilities from {cliputil} to be installed.', file=sys.stderr)
elif not outfile: