Closed gabrielittner closed 5 years ago
I might be having a similar issue. When I use Skicka to upload CSV files to a Google Drive, Drive treats them as text files. I can still import them as CSV into Sheets but this is an extra step I don't want the users to have to take. The same CSV's uploaded through the Google Drive GUI interface work normally as CSV's and can be launched from Sheets directly. It seems likely this is a mime type issue. If there is a way to fix this I would love to know it. Thank you!
This is a more general problem with MIMIE types in skicka. The problem is that skicka uses the Go built-in https://golang.org/pkg/net/http/#DetectContentType which is misdetecting .zip for many formats.
I think removing all MIME guessing from skicka is probably the right thing to do. I'm trying out a few things and it looks like letting the server figure things out works well. Typically this means not setting X-Upload-Content-Type
and possibly other things.
I'm using skicka to upload Android
.apk
files from a ci server to a shared Drive folder. Usually they haveapplication/vnd.android.package-archive
as mime type but those uploaded with skicka haveapplication/zip
. The result is that the Google Drive Android app and the systems Downloads app can't open the apk to install it. Could you either fix this or provide a way to manually set the mime type when uploading it?