codesmithtools / Templates

CodeSmith Generator Templates
http://www.codesmithtools.com/product/generator
54 stars 35 forks source link

Fixes #721 [dbsnapshot] Allow Azure and other cloud-based server sources with port number. #722

Closed cyberjetx closed 1 year ago

cyberjetx commented 1 year ago

The issue wasn't permissions exactly. It was the inability to create a directory from the server name/ server source when it's name is like tcp:myCloudData.database.windows.net,5588. So I have added a rudimentary check in the ParseServerName function to look for a colon.

With the example above I choose myCloudData as the parsed server name. I also check for a blank name and if it is I select the computer name as a last resort otherwise we would create a hidden folder eg .MyDatabaseName

I hope this is clear and I am open to input and suggestion.

CLAassistant commented 1 year ago

CLA assistant check
All committers have signed the CLA.

niemyjski commented 1 year ago

Thanks for your PR, I've left some comments above.

niemyjski commented 1 year ago

Fixes https://github.com/codesmithtools/Templates/issues/721

cyberjetx commented 1 year ago

Changes understood and committed.

niemyjski commented 1 year ago

Thanks for your PR!