Improvements for converting to Markdeep scrapped open books with YAML metadata from MIT's PubPub publishing platform.

This commit is contained in:
Offray Vladimir Luna Cárdenas 2022-10-16 21:20:47 -05:00
parent 2bb50789ea
commit fd35707625

View File

@ -46,6 +46,11 @@ Markdeep >> body: anObject [
body := anObject body := anObject
] ]
{ #category : #accessing }
Markdeep >> bodyReplaceAll: original with: replacement [
self body: (self body copyReplaceAll: original with: replacement)
]
{ #category : #accessing } { #category : #accessing }
Markdeep >> comments [ Markdeep >> comments [
^ comments ifNil: [ ^ comments := true ] ^ comments ifNil: [ ^ comments := true ]
@ -219,6 +224,11 @@ Markdeep >> metadata [
^ metadata ifNil: [ metadata := OrderedDictionary new ] ^ metadata ifNil: [ metadata := OrderedDictionary new ]
] ]
{ #category : #accessing }
Markdeep >> metadata: anOrderedDictionary [
metadata := anOrderedDictionary
]
{ #category : #utilities } { #category : #utilities }
Markdeep >> metadataFromXML: aXMLDocument [ Markdeep >> metadataFromXML: aXMLDocument [
| metaDict | | metaDict |
@ -291,7 +301,7 @@ Markdeep >> tail: anObject [
{ #category : #accessing } { #category : #accessing }
Markdeep >> title [ Markdeep >> title [
^ title ^ title ifNil: [ title := self metadata at: 'title' ]
] ]
{ #category : #accessing } { #category : #accessing }