#!/usr/bin/python3 # downloads and shows an image of arctic ice import requests from subprocess import run url = "http://ocean.dmi.dk/arctic/plots/\ icecover/osisaf_nh_iceextent_daily_5years_en.png" filename = "arctic_ice.png" response = requests.get(url) if response.status_code == 200: with open(filename, "wb") as f: f.write(response.content) else: print ('Error in HTTP request!') run(["fim",filename], check=True)