You can use any brush. Click at the beginning of the line, hold down the shift key, then click where you want to finish.
So, if you want to get a square line, use one of the square brushes. For a round line, use a round brush.
It's a good idea to put the line on a blank, new layer. This way, you can use the move tool to adjust the position of the line, if necessary.
It works with the eraser tool as well. Very handy to tidy up ..