How do I get a final barline or double barline before the repeat start line?

See here