Quick fix to make updating of all documentation

possible. This should be changed for a programatic way of getting a collection of all
declared classes that are a instance of 
GrafoscopioDocumentation.
This commit is contained in:
Offray Vladimir Luna Cárdenas 2017-07-06 22:04:55 +00:00 committed by SantiagoBragagnolo
parent ca88b70241
commit d0e5b635a6
1 changed files with 10 additions and 7 deletions

View File

@ -17,13 +17,10 @@ Class {
{ #category : #updating }
GrafoscopioDocumentation class >> listOutdatedDocs [
"I return the list of all documentent where the local copy and the remote copy doesn't match"
| docsRepo |
docsRepo := self newDefault.
^ docsRepo documents reject: [ :doc | (docsRepo isFileUpdatedFor: doc) ]
^ self newDefault listOutdatedDocs
]
{ #category : #'as yet unclassified' }
{ #category : #'instance creation' }
GrafoscopioDocumentation class >> newDefault [
^ self new
]
@ -35,7 +32,7 @@ GrafoscopioDocumentation class >> update [
{ #category : #updating }
GrafoscopioDocumentation class >> updateAll [
self allInstancesDo: [ :docs | docs update ]
{GrafoscopioDocs . DatavizDocs . OffshoreLeaksDocs} do: [ :docs | docs update ]
]
{ #category : #updating }
@ -88,6 +85,12 @@ GrafoscopioDocumentation >> isFileUpdatedFor: relativeFilePath [
with: (self repository lastHashNumberFor: relativeFilePath) ]
]
{ #category : #updating }
GrafoscopioDocumentation >> listOutdatedDocs [
"I return the list of all documentent where the local copy and the remote copy doesn't match"
^ self documents reject: [ :doc | (self isFileUpdatedFor: doc) ]
]
{ #category : #accessing }
GrafoscopioDocumentation >> localPlace [
^ localPlace ifNil: [
@ -136,7 +139,7 @@ GrafoscopioDocumentation >> repository: anObject [
{ #category : #updating }
GrafoscopioDocumentation >> update [
(self class listOutdatedDocs)
(self listOutdatedDocs)
ifEmpty: [
self inform: 'All documents in the ', self name,' collection are already updated'.
^ self ]