How to make the tab character 4 spaces instead of 8 spaces in nano?

When I press TAB in nano editor, the cursor will jump with 8 spaces like this:

def square(x):
        return x * x
def cube(y):
        return y * y * y

how can I set the tab stop width to 4 spaces to display like this:

def square(x):
    return x * x
def cube(y):
    return y * y * y

7 Answers
7

Leave a Comment