add support for sftp custom port

per @Xenopathic on #12878 re submitting.
Don't remove ending new-line