Describe the feature or problem you’d like to solve
A clear and concise description of what the feature or problem is.
(type -p wget >/dev/null || (sudo apt update && sudo apt 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
- A notable feature of the DEB822 format compared to
/etc/apt/sources.list is its friendliness towards Here Documents. I'll use a configuration change in Docker Engine as an example.
- For
/etc/apt/sources.list,
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo tee /etc/apt/sources.list.d/docker.sources <<EOF
Types: deb
URIs: https://download.docker.com/linux/ubuntu
Suites: $(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}")
Components: stable
Signed-By: /etc/apt/keyrings/docker.asc
EOF
Proposed solution
How will it benefit CLI and its users?
- This is actually a cheap version of Debian/ubuntu.
Additional context
Add any other context like screenshots or mockups are helpful, if applicable.
Describe the feature or problem you’d like to solve
A clear and concise description of what the feature or problem is.
Ubuntu 24.04. Currently, the outdated/etc/apt/sources.list.dis still being used for https://github.com/cli/cli/blob/v2.93.0/docs/install_linux.md#debian . See https://discourse.ubuntu.com/t/spec-apt-deb822-sources-by-default/29333 ./etc/apt/sources.listis its friendliness towardsHere Documents. I'll use a configuration change in Docker Engine as an example./etc/apt/sources.list,Proposed solution
How will it benefit CLI and its users?
Additional context
Add any other context like screenshots or mockups are helpful, if applicable.