Created
June 23, 2012 13:22
-
-
Save triffid/2978294 to your computer and use it in GitHub Desktop.
slic3r machine readable options
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
slic3r --help | perl -ne '/^\s+([A-Z].*?)\s+options.*?:$/ && do { if ($description) { print "\t\t$description\n"; $description = ""; } print "SECTION $1\n"; }; /^\s+((-\S,\s*)?--(\S+))(\s+(.*))/ && do { if ($description) { print "\t\t$description\n"; $description = ""; }; print "\tOPTION $3\n"; $description = " $5"; }; /^\s{24}(\S.*)/ && (length($description) != 0) && do { $description .= $1 }; END { print "\t\t$description\n"; }' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment