chiark
/
gitweb
/
~ianmdlvl
/
reprap-play.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
70421db
)
commitid.scad.pl: Use m//g to split up for S
author
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Fri, 5 Feb 2016 18:27:42 +0000
(18:27 +0000)
committer
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Fri, 5 Feb 2016 18:27:42 +0000
(18:27 +0000)
commitid.scad.pl
patch
|
blob
|
history
diff --git
a/commitid.scad.pl
b/commitid.scad.pl
index 5a61f415fdc353002336ed71a73645bf7bc8c88a..c09ce6ab4f635c64a7a0f33b074aee0c525330c0 100755
(executable)
--- a/
commitid.scad.pl
+++ b/
commitid.scad.pl
@@
-274,7
+274,8
@@
sub gentextmodule_plusq ($$) {
my $l = length $s;
gentextmodule($form, $s);
if (!($l & 1) && $l>=4) {
- gentextmodule("${form}S", substr($s,0,$l/2), substr($s,$l/2));
+ my $e = $l/2;
+ gentextmodule("${form}S", $s =~ m/.{$e}/g);
} else {
$gtm_demo_j++;
}