Skip to content

Commit 8128fb1

Browse files
authored
Merge pull request #4465 from akesandgren/use_cp-dR_not-cp-a
use `cp -dR` instead of `cp -a` for shell script extraction
2 parents e636530 + 0f18f73 commit 8128fb1

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

easybuild/tools/filetools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@
161161
# tar.Z: using compress (LZW), but can be handled with gzip so use 'z'
162162
'.tar.z': "tar xzf %(filepath)s",
163163
# shell scripts don't need to be unpacked, just copy there
164-
'.sh': "cp -a %(filepath)s .",
164+
'.sh': "cp -dR %(filepath)s .",
165165
}
166166

167167
ZIPPED_PATCH_EXTS = ('.bz2', '.gz', '.xz')

test/framework/filetools.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ def test_extract_cmd(self):
104104
('test.txz', "unset TAPE; unxz test.txz --stdout | tar x"),
105105
('test.iso', "7z x test.iso"),
106106
('test.tar.Z', "tar xzf test.tar.Z"),
107-
('test.foo.bar.sh', "cp -a test.foo.bar.sh ."),
107+
('test.foo.bar.sh', "cp -dR test.foo.bar.sh ."),
108108
# check whether extension is stripped correct to determine name of target file
109109
# cfr. https://github.com/easybuilders/easybuild-framework/pull/3705
110110
('testbz2.bz2', "bunzip2 -c testbz2.bz2 > testbz2"),

0 commit comments

Comments
 (0)