Insert code into a latex doc. without leading tabs
Not a very good solution (automatical would be ideal), but this works:
Use gobble
-setting to remove characters from start.
Example
Remove two tabs (= 8 spaces) from start:
\begin{lstlisting}[gobble=8]