func (fileProvider FileProvider) Contents(srcPath string) ([]byte, error) {
	if strings.HasPrefix(srcPath, fileSchema) {  
		trimmedPath, err := fileProvider.trimmedFilePath(srcPath)
		if err != nil {
			return nil, err
		}
		return fileProvider.filedownloader.ReadLocalFile(trimmedPath)
	}
	return fileProvider.filedownloader.GetRemoteContents(srcPath)
}
Contents returns the contents of remote or local URL
package input
import (
	"net/url"
	"path"
	"path/filepath"
	"strings"
	"github.com/bitrise-io/go-utils/pathutil"
)
const (
	fileSchema = "file://"
)
type FileDownloader interface {
	Get(destination, source string) error
	GetRemoteContents(source string) ([]byte, error)
	ReadLocalFile(path string) ([]byte, error)
}
type FileProvider struct {
	filedownloader FileDownloader
}
func NewFileProvider(filedownloader FileDownloader) FileProvider {
	return FileProvider{
		filedownloader: filedownloader,
	}
}
func (fileProvider FileProvider) LocalPath(path string) (string, error) {
	if strings.HasPrefix(path, fileSchema) {  
		return fileProvider.trimmedFilePath(path)
	}
	return fileProvider.downloadFileToLocalPath(path)
}