2

I'm trying to download a zipfile from a Github repository with this command:

wget --no-check-certificate https://github.com/brendenlake/omniglot/blob/master/python/images_evaluation.zip -O /tmp/images_evaluation.zip

But it doesn't download a valid zip file. I suppose that it downloads the HTML file that the browser shows if you click on the url.

How can I download a zip file from a public Github repository using wget?

VansFannel
  • 211
  • 1
  • 3
  • 8

2 Answers2

2

I have found the answer here: https://unix.stackexchange.com/a/387912/132714

I have changed the blob:

wget --no-check-certificate https://github.com/brendenlake/omniglot/blob/master/python/images_evaluation.zip -O /tmp/images_evaluation.zip

With raw:

wget --no-check-certificate https://github.com/brendenlake/omniglot/raw/master/python/images_evaluation.zip -O /tmp/images_evaluation.zip

And now it downloads a valid zip file.

VansFannel
  • 211
  • 1
  • 3
  • 8
1

try using git clone instead of wget