MCSmtpRepository.st
changeset 900 34c44e0f7cee
parent 680 dee895391882
child 1022 b561a6a0a2d7
equal deleted inserted replaced
899:e5b992f2ff33 900:34c44e0f7cee
     8 !
     8 !
     9 
     9 
    10 
    10 
    11 !MCSmtpRepository class methodsFor:'as yet unclassified'!
    11 !MCSmtpRepository class methodsFor:'as yet unclassified'!
    12 
    12 
    13 description
       
    14 	^ 'SMTP'
       
    15 !
       
    16 
       
    17 morphicConfigure
    13 morphicConfigure
    18 	| address |
    14 	| address |
    19 	address := UIManager default request: 'Email address:' translated.
    15 	address := UIManager default request: 'Email address:' translated.
    20 	^ address isEmpty ifFalse: [self new emailAddress: address]
    16 	^ address isEmpty ifFalse: [self new emailAddress: address]
    21 ! !
    17 ! !
    22 
    18 
       
    19 !MCSmtpRepository class methodsFor:'queries'!
       
    20 
       
    21 description
       
    22 	^ 'SMTP'
       
    23 ! !
       
    24 
       
    25 !MCSmtpRepository methodsFor:'accessing'!
       
    26 
       
    27 description
       
    28 	^ 'mailto://', email
       
    29 ! !
       
    30 
    23 !MCSmtpRepository methodsFor:'as yet unclassified'!
    31 !MCSmtpRepository methodsFor:'as yet unclassified'!
    24 
       
    25 basicStoreVersion: aVersion
       
    26 	MailSender sendMessage: (self messageForVersion: aVersion)
       
    27 !
       
    28 
    32 
    29 bodyForVersion: aVersion
    33 bodyForVersion: aVersion
    30 	^ String streamContents:
    34 	^ String streamContents:
    31 		[ :s |
    35 		[ :s |
    32 		s nextPutAll: 'from version info:'; cr; cr.
    36 		s nextPutAll: 'from version info:'; cr; cr.
    33 		s nextPutAll:  aVersion info summary]
    37 		s nextPutAll:  aVersion info summary]
    34 !
       
    35 
       
    36 description
       
    37 	^ 'mailto://', email
       
    38 !
    38 !
    39 
    39 
    40 emailAddress: aString
    40 emailAddress: aString
    41 	email := aString	
    41 	email := aString	
    42 !
    42 !
    56 	"Prepare the gzipped data"
    56 	"Prepare the gzipped data"
    57 	data := RWBinaryOrTextStream on: String new.
    57 	data := RWBinaryOrTextStream on: String new.
    58 	aVersion fileOutOn: data.
    58 	aVersion fileOutOn: data.
    59 	message addAttachmentFrom: data reset withName: aVersion fileName.
    59 	message addAttachmentFrom: data reset withName: aVersion fileName.
    60 	^ message
    60 	^ message
    61 !
    61 ! !
       
    62 
       
    63 !MCSmtpRepository methodsFor:'printing & storing'!
       
    64 
       
    65 basicStoreVersion: aVersion
       
    66 	MailSender sendMessage: (self messageForVersion: aVersion)
       
    67 ! !
       
    68 
       
    69 !MCSmtpRepository methodsFor:'queries'!
    62 
    70 
    63 subjectForVersion: aVersion
    71 subjectForVersion: aVersion
    64 	^ '[Package] ', aVersion info name
    72 	^ '[Package] ', aVersion info name
    65 ! !
    73 ! !
    66 
    74 
    67 !MCSmtpRepository class methodsFor:'documentation'!
    75 !MCSmtpRepository class methodsFor:'documentation'!
    68 
    76 
    69 version
    77 version
    70     ^ '$Header: /cvs/stx/stx/goodies/monticello/MCSmtpRepository.st,v 1.4 2012-09-11 21:28:42 cg Exp $'
    78     ^ '$Header: /cvs/stx/stx/goodies/monticello/MCSmtpRepository.st,v 1.5 2014-02-12 14:53:31 cg Exp $'
    71 !
    79 !
    72 
    80 
    73 version_CVS
    81 version_CVS
    74     ^ '$Header: /cvs/stx/stx/goodies/monticello/MCSmtpRepository.st,v 1.4 2012-09-11 21:28:42 cg Exp $'
    82     ^ '$Header: /cvs/stx/stx/goodies/monticello/MCSmtpRepository.st,v 1.5 2014-02-12 14:53:31 cg Exp $'
    75 !
    83 !
    76 
    84 
    77 version_SVN
    85 version_SVN
    78     ^ '§Id: MCSmtpRepository.st 5 2010-08-29 07:30:29Z vranyj1 §'
    86     ^ '$Id: MCSmtpRepository.st,v 1.5 2014-02-12 14:53:31 cg Exp $'
    79 ! !
    87 ! !
       
    88