mivinci / hugo-theme-minima

A clean and minimal Hugo theme.
https://mivinci.github.io/hugo-theme-minima
MIT License
130 stars 37 forks source link

how to change tab size #26

Closed huanggze closed 2 years ago

huanggze commented 2 years ago

I have a makefile snippet like below

image

it was rendered as below with tab size = 8. Is there any way to change tab size to 4, so a tab is equal to four whitespaces.

image
mivinci commented 2 years ago

Most of the renderers, including the one that Hugo uses, take a tab as an 8-spaces long indent. It is encouraged to convert a tab into 4 spaces which can be done by switching on the relevant option in your editor.

huanggze commented 2 years ago

Thanks for your reply. Actually, my editor GoLand works fine, it is the renderer has this indent issue.

mivinci commented 2 years ago

I've tried on my VSCode with a tab and the renderer works as you expected. Does GoLand convert a tab into 4 spaces for you? I mean when you press the tab button, does it actually show in the editor as 4 plain spaces instead of a \t?