[squeak-dev] The Trunk: Monticello-mt.781.mcz

commits at source.squeak.org commits at source.squeak.org
Sat Jul 2 07:56:13 UTC 2022

Marcel Taeumel uploaded a new version of Monticello to project The Trunk:

==================== Summary ====================

Name: Monticello-mt.781
Author: mt
Time: 2 July 2022, 9:56:11.742503 am
UUID: c926f650-7352-6241-927a-0e052dbbd824
Ancestors: Monticello-mt.780

Extend MC repository instantiation interface to allow HTTPS, not only HTTP.

=============== Diff against Monticello-mt.780 ===============

Item was changed:
  ----- Method: MCRepository class>>location:username:password: (in category 'instance creation') -----
  location: urlOrPath username: user password: pass
  	"Answer an MCRepository for the given url or path. Accepted locations are:
  		- http, and ftp urls (i.e., http://source.squeak.org/trunk)
  		- directory paths (i.e., C:\Squeak\packages)
  		- directory matches (i.e., C:\Squeak\packages\*)
  	If provided, the supplied user name and password will be used."
  	| url |
  	(urlOrPath findString: '://') > 0 ifTrue:[
  		url := urlOrPath asUrl.
  		^ url scheme caseOf: {
  			['ftp'] -> [MCFtpRepository 
  							host: url authority
  							 directory: url pathString allButFirst
  							user: user 
  							password: user].
  			['http'] -> [MCHttpRepository 
  							location: urlOrPath 
  							user: user 
  							password: pass].
+ 			['https'] -> [MCHttpRepository 
+ 							location: urlOrPath 
+ 							user: user 
+ 							password: pass].
  		} otherwise:[self error: 'Unsupported scheme: ', url scheme].
  	(urlOrPath endsWith: '*') ifTrue:[
  		^MCSubDirectoryRepository new 
  				directory: (FileDirectory on: urlOrPath allButLast)].
  			directory: (FileDirectory on: urlOrPath)!

More information about the Squeak-dev mailing list