From b60fa8b2e5531a2112f96f9370ae5921417ee5ce Mon Sep 17 00:00:00 2001 From: Offray Luna Date: Tue, 17 Jan 2023 17:24:08 -0500 Subject: [PATCH] Nim file exporter as a core utility belonging to MiniDocs. --- repository/TiddlyWiki/Tiddler.class.st | 27 ++------------------------ 1 file changed, 2 insertions(+), 25 deletions(-) diff --git a/repository/TiddlyWiki/Tiddler.class.st b/repository/TiddlyWiki/Tiddler.class.st index 1cf0973..7f923fd 100644 --- a/repository/TiddlyWiki/Tiddler.class.st +++ b/repository/TiddlyWiki/Tiddler.class.st @@ -202,8 +202,8 @@ Tiddler >> exportSTONFileOptimized [ | exporter wikiFolder tiddlersFolder | wikiFolder := self wiki folder. - exporter := wikiFolder / 'scripts' / 'stringAsFileInto'. - exporter exists ifFalse: [ self installTiddlerExporter ]. + exporter := MiniDocs appFolder / 'scripts' / 'stringAsFileInto'. + exporter exists ifFalse: [ self installNimFileExporter ]. tiddlersFolder := wikiFolder / 'tiddlers'. tiddlersFolder exists ifFalse: [ tiddlersFolder ensureCreateDirectory ]. @@ -291,29 +291,6 @@ Tiddler >> importFedWikiPage: pageViewUrlString [ ^ STONJSON fromString: pageData retrieveContents ] -{ #category : #accessing } -Tiddler >> installTiddlerExporter [ - | folder | - folder := (self wiki folder). - folder := (folder / 'scripts') ensureCreateDirectory. - - ZnClient new - url: 'https://mutabit.com/repos.fossil/mutabit/uv/wiki/scripts/stringAsFileInto'; - downloadTo: folder / 'stringAsFileInto'. - - ZnClient new - url: 'https://mutabit.com/repos.fossil/mutabit/doc/trunk/wiki/scripts/stringAsFileInto.nim'; - downloadTo: folder / 'stringAsFileInto.nim'. - - OSSUnixSubprocess new - command: 'chmod'; - arguments: { '+x' . (folder / 'stringAsFileInto') fullName }; - workingDirectory: folder fullName; - redirectStdout; - redirectStderr; - runAndWaitOnExitDo: [ :process :outString | ^ outString ] -] - { #category : #testing } Tiddler >> isImage [