Sha256: 439be19d934a23432399516e1cbaaba89fbc9c394824cad83ebf0d24d1cb3d29
Contents?: true
Size: 1.08 KB
Versions: 1
Compression:
Stored size: 1.08 KB
Contents
# !/usr/bin/env ruby require "optparse" require "optparse_plus" require "debug" $:.unshift File.join(__dir__, "../lib") require "autocad" # require "autocad/extensions/faa" class PwApp include OptparsePlus::Main include OptparsePlus::CLILogging main do |dir| save_dir = dir || Pathname.getwd directory_path = Pathname(save_dir).expand_path unless directory_path.directory? exit_now! "arg directory: #{directory_path} doesn't exist" end model = options["model"] model = model || false Autocad.save_open_drawings(dir: directory_path, exit: options["exit"], model: ) unless options["exit"] require "debug"; binding.irb end end description "Save the currently open projectwise drawing" on("-m","--[no-]model", TrueClass, "Save pdf as modelspace") on("-e", "--[no-]exit", TrueClass, "Close the Autocad instance") options["exit"] = true version Autocad::VERSION use_log_level_option description "Saves the current autocad drawing that is opened" arg :save_dir, :optional go! end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
autocad-0.4.6 | exe/pw_print |