Fixing repeated medatada when exporting to Markdeep.
This commit is contained in:
parent
53910fa840
commit
13f9b8050e
@ -35,6 +35,7 @@ LePage >> asMarkdeep [
|
|||||||
self metadata
|
self metadata
|
||||||
at: 'version'
|
at: 'version'
|
||||||
ifPresent: [ :version | markdeep metadata at: 'version' put: version ].
|
ifPresent: [ :version | markdeep metadata at: 'version' put: version ].
|
||||||
|
markdeep head: nil.
|
||||||
^ markdeep
|
^ markdeep
|
||||||
]
|
]
|
||||||
|
|
||||||
@ -180,7 +181,7 @@ LePage >> markdownFileName [
|
|||||||
{ #category : #'*MiniDocs' }
|
{ #category : #'*MiniDocs' }
|
||||||
LePage >> metadata [
|
LePage >> metadata [
|
||||||
|
|
||||||
^ self options at: 'metadata' ifAbsentPut: [ self metadataUpdate]
|
^ self metadataUpdate
|
||||||
]
|
]
|
||||||
|
|
||||||
{ #category : #'*MiniDocs' }
|
{ #category : #'*MiniDocs' }
|
||||||
@ -190,7 +191,7 @@ LePage >> metadataUpdate [
|
|||||||
at: 'id' put: self uidString;
|
at: 'id' put: self uidString;
|
||||||
at: 'title' put: self contentAsString;
|
at: 'title' put: self contentAsString;
|
||||||
at: 'created' put: self createTime greaseString;
|
at: 'created' put: self createTime greaseString;
|
||||||
at: 'modified' put: self latestEditTime greaseString;
|
at: 'modified' put: self getLatestEditTime greaseString;
|
||||||
at: 'creator' put: self createEmail greaseString;
|
at: 'creator' put: self createEmail greaseString;
|
||||||
at: 'modifier' put: self editEmail greaseString;
|
at: 'modifier' put: self editEmail greaseString;
|
||||||
yourself
|
yourself
|
||||||
|
@ -294,8 +294,11 @@ Markdeep >> headContents [
|
|||||||
nextPutAll: line;
|
nextPutAll: line;
|
||||||
nextPut: Character lf
|
nextPut: Character lf
|
||||||
].
|
].
|
||||||
stream nextPutAll:
|
self metadata keysAndValuesDo: [:k :v |
|
||||||
'<st-data>', (STON toStringPretty: self metadata), '</st-data>'.
|
k = 'lang'
|
||||||
|
ifTrue: [ stream nextPutAll: ' <meta lang="', v,'">'; cr. ]
|
||||||
|
ifFalse: [ stream nextPutAll: ' <meta name="', k, '" content="', v,'">'; cr. ]
|
||||||
|
].
|
||||||
stream
|
stream
|
||||||
nextPutAll: '</head>';
|
nextPutAll: '</head>';
|
||||||
nextPut: Character lf.
|
nextPut: Character lf.
|
||||||
|
Loading…
Reference in New Issue
Block a user