Skip to content

README code mixes tabs and spaces in the same block #11193

@Stefan-Heimersheim

Description

@Stefan-Heimersheim

Describe the bug

The code below used spaces to indent two of the lines, and tabs for the other 6 lines. This makes indenting inconsistent in settings where tabs are not rendered as 8 spaces.

Affected version

gh version 2.74.2 (2025-06-18)

Steps to reproduce the behavior

See the code block in this README

Expected vs actual behavior

Actual code, highlighting tabs and spaces with respective unicode characters

(type -p wget >/dev/null || (sudo apt update && sudo apt-get install wget -y)) \
␉ && sudo mkdir -p -m 755 /etc/apt/keyrings \
␣␣␣␣␣␣␣␣&& out=$(mktemp) && wget -nv -O$out https://cli.github.com/packages/githubcli-archive-keyring.gpg \
␣␣␣␣␣␣␣␣&& cat $out | sudo tee /etc/apt/keyrings/githubcli-archive-keyring.gpg > /dev/null \
 ␉ && sudo chmod go+r /etc/apt/keyrings/githubcli-archive-keyring.gpg \
 ␉ && sudo mkdir -p -m 755 /etc/apt/sources.list.d \
 ␉ && echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null \
 ␉ && sudo apt update \
 ␉ && sudo apt install gh -y

Expected code: Use either tabs or spaces.

(type -p wget >/dev/null || (sudo apt update && sudo apt-get install wget -y)) \
	&& sudo mkdir -p -m 755 /etc/apt/keyrings \
	&& out=$(mktemp) && wget -nv -O$out https://cli.github.com/packages/githubcli-archive-keyring.gpg \
	&& cat $out | sudo tee /etc/apt/keyrings/githubcli-archive-keyring.gpg > /dev/null \
	&& sudo chmod go+r /etc/apt/keyrings/githubcli-archive-keyring.gpg \
	&& sudo mkdir -p -m 755 /etc/apt/sources.list.d \
	&& echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/githubcli-archive-keyring.gpg] https://cli.github.com/packages stable main" | sudo tee /etc/apt/sources.list.d/github-cli.list > /dev/null \
	&& sudo apt update \
	&& sudo apt install gh -y

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingdocshelp wantedContributions welcome

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions