palabra 1.18.0 → 1.19.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/ChangeLog +5 -0
- package/lib/parser/extract.js +4 -1
- package/package.json +1 -1
package/ChangeLog
CHANGED
package/lib/parser/extract.js
CHANGED
|
@@ -7,6 +7,9 @@ const exts = [
|
|
|
7
7
|
'.xz',
|
|
8
8
|
];
|
|
9
9
|
|
|
10
|
+
const CONTINUE = '-c';
|
|
11
|
+
const NOT_OVERWRITE = '-nc';
|
|
12
|
+
|
|
10
13
|
export const isArchive = ({url}) => {
|
|
11
14
|
const ext = extname(new URL(url).pathname);
|
|
12
15
|
return exts.includes(ext);
|
|
@@ -23,7 +26,7 @@ export const extract = (letra) => {
|
|
|
23
26
|
const renderedURL = rendy(url, letra);
|
|
24
27
|
const filename = basename(renderedURL);
|
|
25
28
|
|
|
26
|
-
commands.push(`wget ${renderedURL} -O /tmp/${filename}`);
|
|
29
|
+
commands.push(`wget ${CONTINUE} ${NOT_OVERWRITE} ${renderedURL} -O /tmp/${filename}`);
|
|
27
30
|
commands.push(`rm -rf ${directorio}/${name}`);
|
|
28
31
|
commands.push(`mkdir -p ${directorio}/${name}`);
|
|
29
32
|
commands.push(`tar xf /tmp/${filename} -C ${directorio}`);
|