How can I avoid that Github rotates my jpg in my readme.md?

steenhulthin picture steenhulthin · Oct 17, 2013 · Viewed 12.1k times · Source

I have added a image reference in my readme.md on github. The picture is a portrait format photo, but when I view it on the github page the picture is rotated.

I have tried clone the repo to a new location to confirm that the picture is indeed still portrait as expected in the repo.

The image part of the readme.md:

Here is a picture of the hardware setup. ![picture of the hardware setup](HelloButtonModule.jpg)

This is the affected github repo

Update

Now I am really baffled I tried to simplify the problem in a new repo, but the picture shows up unrotated as (originally) expected.

Update

I have created a repo with an exact copy of the picture. Then the picture is rotated.

Answer

A. William B. Allen picture A. William B. Allen · Dec 15, 2014

You could try simply opening the file and then re-saving it. You may need to rotate 360 degrees before you save, however, this should work.