The Archive.create() features a workdir keyword argument, the method is supposed to temporarily change to that directory if given, see #20. This works as expected if the working directory is absolute, but fails when passing a relative path.
Consider the following setup:
$ ls -laR work
work:
total 0
drwxr-xr-x 1 rolf rk 8 May 1 12:35 .
drwxr-xr-x 1 rolf rk 278 May 1 12:35 ..
drwxr-xr-x 1 rolf rk 8 May 1 12:35 base
work/base:
total 0
drwxr-xr-x 1 rolf rk 8 May 1 12:35 .
drwxr-xr-x 1 rolf rk 8 May 1 12:35 ..
drwxr-xr-x 1 rolf rk 14 May 1 12:35 data
work/base/data:
total 4
drwxr-xr-x 1 rolf rk 14 May 1 12:35 .
drwxr-xr-x 1 rolf rk 8 May 1 12:35 ..
-rw-r--r-- 1 rolf rk 385 Apr 18 23:11 rnd.dat
Now, creating an archive passing an absolute path as workdir works as expected:
The
Archive.create()
features aworkdir
keyword argument, the method is supposed to temporarily change to that directory if given, see #20. This works as expected if the working directory is absolute, but fails when passing a relative path.Consider the following setup:
Now, creating an archive passing an absolute path as
workdir
works as expected:Trying the same using a relative path fails: