<div dir="ltr"><div><div><div><div><div>Hi All,<br><br></div>learning curve is steep :)<br><br></div>From<br>CX08$ more c1.c<br>struct yo {<br>int i;<br>int j;<br>};<br><br>int f(int i, int j)<br>{ if(i){i++;} else {j++;}<br>  return(i+j);<br>}<br><br></div>I'd like to get <br>CX08$ more c1.c<br>struct yo <br>{ int i;<br>  int j;<br>};<br><br>int f(int i, int j)<br>{ if(i)<br>  { i++;<br>  }<br>  else<br>  { j++;<br>    return(i+j);<br>  }<br>}<br><br><br></div>I found BreakBeforeBraces Allman about ok but has an extra line I don't want<br><br>CX08$ /home/phi/llvmbuild/bin/clang-format c.c<br>struct yo<br></div>{ <----- don't want this \n<br><div>  int i;<br>  int j;<br>};<br><br>int f(int i, int j)<br>{<----- don't want this \n<br>  if (i)<br>  {<----- don't want this \n<br>    i++;<br>  }<br>  else<br>  {<----- don't want this \n<br>    j++;<br>  }<br>  return (i + j);<br>}<br><br><br></div><div>Any ideas how to tweak .clang-format <br><br></div><div>Try and fail on all option is a bit slow :)<br><br><br></div></div>