Commiting detached image.

This commit is contained in:
Offray Vladimir Luna Cárdenas 2024-07-02 18:18:57 -05:00
parent c7fca28305
commit 7ae2e6c7a7
2 changed files with 33 additions and 2 deletions

View File

@ -214,7 +214,10 @@ Tiddler >> exportSTONFile [
{ #category : #accessing } { #category : #accessing }
Tiddler >> exportSTONFileInto: subfolder [ Tiddler >> exportSTONFileInto: subfolder [
| stonFile | | stonFile tiddlersSubfolder |
tiddlersSubfolder := self wiki folder / subfolder.
tiddlersSubfolder exists
ifFalse: [ tiddlersSubfolder ensureCreateDirectory ].
stonFile := self wiki folder / subfolder / self fileName. stonFile := self wiki folder / subfolder / self fileName.
^ MarkupFile exportAsFileOn: stonFile containing: self asStonStringPretty ^ MarkupFile exportAsFileOn: stonFile containing: self asStonStringPretty
] ]
@ -537,6 +540,16 @@ Tiddler >> tagsAsString [
^ response contents ^ response contents
] ]
{ #category : #accessing }
Tiddler >> tagsReformating [
| response |
self tags class ~= ByteString ifTrue: [ ^ self ].
response := Set new.
response add: self tags.
self tags: response.
]
{ #category : #accessing } { #category : #accessing }
Tiddler >> text [ Tiddler >> text [

View File

@ -262,6 +262,10 @@ TiddlyWiki >> exportJSONFile [
^ MarkupFile exportAsFileOn: self jsonFile containing: rawJsonTiddlers ^ MarkupFile exportAsFileOn: self jsonFile containing: rawJsonTiddlers
] ]
{ #category : #accessing }
TiddlyWiki >> exportJSONFileFromTiddlers [
]
{ #category : #accessing } { #category : #accessing }
TiddlyWiki >> exportJSONFileOptimized [ TiddlyWiki >> exportJSONFileOptimized [
@ -493,6 +497,18 @@ TiddlyWiki >> importJSONLink [
^ self fromString: self remoteTiddlersContentsString ^ self fromString: self remoteTiddlersContentsString
] ]
{ #category : #accessing }
TiddlyWiki >> importSTONFilesFrom: aFolder [
| tiddlerFiles |
self folder: aFolder parent.
tiddlerFiles := aFolder children
select: [ :localFile | localFile basename endsWith: '.ston' ].
self tiddlers: (tiddlerFiles collect: [ :each | | tempTiddler|
tempTiddler := STON fromString: each contents.
tempTiddler wiki: self.
tempTiddler])
]
{ #category : #accessing } { #category : #accessing }
TiddlyWiki >> installJsonExporter [ TiddlyWiki >> installJsonExporter [
@ -718,9 +734,11 @@ TiddlyWiki >> oldestCreatedTiddler [
{ #category : #accessing } { #category : #accessing }
TiddlyWiki >> printOn: aStream [ TiddlyWiki >> printOn: aStream [
| printName |
printName := self name ifNil: ['unamed'].
super printOn: aStream. super printOn: aStream.
aStream aStream
nextPutAll: '( ', self name ,' )' nextPutAll: '( ', printName ,' )'
] ]
{ #category : #accessing } { #category : #accessing }