A Canberra man who breached COVID-19 isolation to attack his neighbour with an axe has been sentenced to nearly four years in jail.