Nim file exporter as a core utility belonging to MiniDocs.
This commit is contained in:
parent
8422570ebd
commit
b60fa8b2e5
@ -202,8 +202,8 @@ Tiddler >> exportSTONFileOptimized [
|
|||||||
|
|
||||||
| exporter wikiFolder tiddlersFolder |
|
| exporter wikiFolder tiddlersFolder |
|
||||||
wikiFolder := self wiki folder.
|
wikiFolder := self wiki folder.
|
||||||
exporter := wikiFolder / 'scripts' / 'stringAsFileInto'.
|
exporter := MiniDocs appFolder / 'scripts' / 'stringAsFileInto'.
|
||||||
exporter exists ifFalse: [ self installTiddlerExporter ].
|
exporter exists ifFalse: [ self installNimFileExporter ].
|
||||||
tiddlersFolder := wikiFolder / 'tiddlers'.
|
tiddlersFolder := wikiFolder / 'tiddlers'.
|
||||||
tiddlersFolder exists ifFalse: [ tiddlersFolder ensureCreateDirectory ].
|
tiddlersFolder exists ifFalse: [ tiddlersFolder ensureCreateDirectory ].
|
||||||
|
|
||||||
@ -291,29 +291,6 @@ Tiddler >> importFedWikiPage: pageViewUrlString [
|
|||||||
^ STONJSON fromString: pageData retrieveContents
|
^ 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 }
|
{ #category : #testing }
|
||||||
Tiddler >> isImage [
|
Tiddler >> isImage [
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user