Skip to content

Commit

Permalink
Removed redundant checks to create the output dir.
Browse files Browse the repository at this point in the history
They became useless after adding it to _configure_output_dir
  • Loading branch information
set-soft committed May 26, 2020
1 parent be7a613 commit 46248a6
Showing 1 changed file with 0 additions and 9 deletions.
9 changes: 0 additions & 9 deletions kiplot/kiplot.py
Original file line number Diff line number Diff line change
Expand Up @@ -389,9 +389,6 @@ def _do_drill_plot(self, board, plot_ctrl, output):
if gen_drill:
logger.debug("Generating drill files in "+outdir)

if not os.path.exists(outdir):
os.makedirs(outdir)

if gen_map:
drill_writer.SetMapFileFormat(to.map_options.type)
logger.debug("Generating drill map type {} in {}"
Expand Down Expand Up @@ -479,8 +476,6 @@ def _do_position_plot_csv(self, board, plot_ctrl, output, columns,
modulesStr):
to = output.options.type_options
outdir = plot_ctrl.GetPlotOptions().GetOutputDirectory()
if not os.path.exists(outdir):
os.makedirs(outdir)
name = os.path.splitext(os.path.basename(board.GetFileName()))[0]

topf = None
Expand Down Expand Up @@ -624,8 +619,6 @@ def _do_kibom(self, board, plot_ctrl, output, brd_file):
to = output.options.type_options
format = to.format.lower()
outdir = plot_ctrl.GetPlotOptions().GetOutputDirectory()
if not os.path.exists(outdir):
os.makedirs(outdir)
prj = os.path.splitext(os.path.relpath(brd_file))[0]
logger.debug('Doing BoM, format '+format+' prj: '+prj)
cmd = [misc.CMD_KIBOM, prj+'.xml',
Expand All @@ -642,8 +635,6 @@ def _do_kibom(self, board, plot_ctrl, output, brd_file):
def _do_ibom(self, board, plot_ctrl, output, brd_file):
check_script(misc.CMD_IBOM, misc.URL_IBOM)
outdir = plot_ctrl.GetPlotOptions().GetOutputDirectory()
if not os.path.exists(outdir):
os.makedirs(outdir)
prj = os.path.splitext(os.path.relpath(brd_file))[0]
logger.debug('Doing Interactive BoM, prj: '+prj)
cmd = [misc.CMD_IBOM, brd_file,
Expand Down

0 comments on commit 46248a6

Please sign in to comment.