Improving JSON exporter installation.

This commit is contained in:
ruidajo 2022-03-07 14:04:09 -05:00
parent 60944f57bd
commit 11fb92ca06

View File

@ -165,7 +165,7 @@ TiddlyWiki >> exportJSONFileOptimized [
OSSUnixSubprocess new
command: exporter fullName;
arguments: {};
workingDirectory: wikiFolder fullName;
workingDirectory: exporter parent fullName;
redirectStdout;
redirectStderr;
runAndWaitOnExitDo: [ :process :outString | ^ outString ]
@ -291,9 +291,20 @@ TiddlyWiki >> importJSONFile [
{ #category : #accessing }
TiddlyWiki >> installJsonExporter [
| folder |
folder := (self file parent / 'scripts') ensureCreateDirectory.
ZnClient new
url: 'https://mutabit.com/repos.fossil/mutabit/uv/wiki/scripts/exportJsonFile';
downloadTo: self file parent / 'scripts' / 'exportJsonFile'
downloadTo: folder / 'exportJsonFile'.
OSSUnixSubprocess new
command: 'chmod';
arguments: { '+x' . (folder / 'exportJsonFile') fullName };
workingDirectory: folder fullName;
redirectStdout;
redirectStderr;
runAndWaitOnExitDo: [ :process :outString | ^ outString ]
"Descarga el archivo
https://mutabit.com/repos.fossil/mutabit/uv/wiki/scripts/exportJsonFile
a la subcarpeta del wiki ./scripts/exportJsonFile.