How do I remove rounded borders from windows in Ubuntu 18.04 with GNOME shell?

Solution 1:

Adding the following lines to ~/.config/gtk-3.0/gtk.css have made the corners square:

.titlebar,
.titlebar .background {
  border-top-left-radius: 0px;
  border-top-right-radius: 0px;
  border-bottom-left-radius: 0px;
  border-bottom-right-radius: 0px;
}

As an alternative, you can use border-radius: 0px 0px 0px 0px.