Easy when you know it:
for file in *.JPG; do convert $file -auto-orient oriented-$file; done
If you want to apply this to only one image:
convert imageinfile -auto-orient imageoutfile
Easy when you know it:
for file in *.JPG; do convert $file -auto-orient oriented-$file; done
If you want to apply this to only one image:
convert imageinfile -auto-orient imageoutfile