Skip to content

Commit

Permalink
Merge pull request #702 from lago-project/create_workdir_in_existing_dir
Browse files Browse the repository at this point in the history
Allow to create a workdir in an existing dir
  • Loading branch information
ovirt-infra authored Apr 2, 2018
2 parents 1b34146 + 91c148c commit 8291249
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion lago/cmd.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,10 @@ def do_init(
with log_utils.LogTask('Initialize and populate prefix', LOGGER):
LOGGER.debug('Using workdir %s', workdir)
workdir = lago_workdir.Workdir(workdir)
if not os.path.exists(workdir.path):
if not (
os.path.exists(workdir.path)
and lago.workdir.Workdir.is_workdir(workdir.path)
):
LOGGER.debug(
'Initializing workdir %s with prefix %s',
workdir.path,
Expand Down

0 comments on commit 8291249

Please sign in to comment.