Improving rebuilded tiddlers JSON.
This commit is contained in:
parent
251f5d3426
commit
7802cfe8f5
@ -152,11 +152,10 @@ Tiddler >> exportSTONFile [
|
|||||||
{ #category : #accessing }
|
{ #category : #accessing }
|
||||||
Tiddler >> exportSTONFileInto: subfolder [
|
Tiddler >> exportSTONFileInto: subfolder [
|
||||||
|
|
||||||
| stonFile output dashedTitle sanitized date |
|
| stonFile output dashedTitle sanitized |
|
||||||
dashedTitle := '-' join: (self title substrings collect: [ :each | each ]).
|
dashedTitle := '-' join: (self title substrings collect: [ :each | each ]).
|
||||||
sanitized := dashedTitle copyWithoutAll: #($¿ $? $! $¡ $/).
|
sanitized := dashedTitle copyWithoutAll: #($¿ $? $! $¡ $/).
|
||||||
date := self uid.
|
stonFile := self wiki file parent / subfolder / (sanitized, '--', self uid, '.ston').
|
||||||
stonFile := self wiki file parent / subfolder / (sanitized, '--', date, '.ston').
|
|
||||||
^ MarkupFile exportAsFileOn: stonFile containing: self asStonStringPretty
|
^ MarkupFile exportAsFileOn: stonFile containing: self asStonStringPretty
|
||||||
]
|
]
|
||||||
|
|
||||||
|
@ -427,7 +427,6 @@ TiddlyWiki >> rebuildTiddlers [
|
|||||||
addAll: (((self largeTiddlersFolder files)
|
addAll: (((self largeTiddlersFolder files)
|
||||||
reject: [ :each | each basename beginsWith: '_shadow.ston' ])
|
reject: [ :each | each basename beginsWith: '_shadow.ston' ])
|
||||||
collect: [ :each | STONJSON fromString: each contents ]);
|
collect: [ :each | STONJSON fromString: each contents ]);
|
||||||
addAll: (STON fromString:shadowTiddlersFile first contents);
|
|
||||||
addAll: (contentTiddlersFiles collect:[ :each | STONJSON fromString: each contents ]).
|
addAll: (contentTiddlersFiles collect:[ :each | STONJSON fromString: each contents ]).
|
||||||
^ stonTiddlers
|
^ stonTiddlers
|
||||||
]
|
]
|
||||||
@ -483,11 +482,12 @@ TiddlyWiki >> resynchronize [
|
|||||||
|
|
||||||
| repository |
|
| repository |
|
||||||
self
|
self
|
||||||
exportJSONFileOptimized;
|
exportJSONFile;
|
||||||
importJSONFile.
|
importJSONFile.
|
||||||
repository := self repository.
|
repository := self repository.
|
||||||
repository update.
|
repository update.
|
||||||
self exportContentTiddlers.
|
self exportContentTiddlers.
|
||||||
|
self exportLargeTiddlers.
|
||||||
repository addRecentChangesFromWiki: self.
|
repository addRecentChangesFromWiki: self.
|
||||||
^ Dictionary new
|
^ Dictionary new
|
||||||
at: 'status' put: repository status;
|
at: 'status' put: repository status;
|
||||||
|
Loading…
Reference in New Issue
Block a user