Score:0

How to remove a repo that isn't in /etc/apt/sources.list?

cn flag

I want to remove a repo (from packages.cloud.google.com) but it isn't in /etc/apt/sources.list. (I haven't reproduced that file because the output is very long, but honestly, it isn't in it) But it does appear in the output of sudo apt update and it is listed when I run apt policy:

t0p@pluto:~$ apt policy
Package files:
 100 /var/lib/dpkg/status
     release a=now

<snipped for length>

 500 https://packages.cloud.google.com/apt cloud-sdk/main i386 Packages
     release o=cloud-sdk,a=cloud-sdk,n=cloud-sdk,l=cloud-sdk,c=main,b=i386
     origin packages.cloud.google.com
 500 https://packages.cloud.google.com/apt cloud-sdk/main amd64 Packages
     release o=cloud-sdk,a=cloud-sdk,n=cloud-sdk,l=cloud-sdk,c=main,b=amd64
     origin packages.cloud.google.com
 500 http://ppa.launchpad.net/atareao/atareao/ubuntu bionic/main i386 Packages

<snip>

The only way I know to remove a repo is to delete its entry in /etc/apt/sources.list. But this one isn't in that file, so I'm at a loss.

Can anyone tell me what I need to do to remove the repo from my system?

cc flag
Have you looked in the /etc/apt/sources.list.d directory?
heynnema avatar
ru flag
In `terminal` do `grep -i packages.cloud.google.com /etc/apt/sources.list.d/*.list` and you'll find it.
Martin Topping avatar
cn flag
t0p@pluto:/etc/apt/sources.list.d$ grep -i packages.cloud.google.com /etc/apt/sources.list.d/*.list /etc/apt/sources.list.d/google-cloud-sdk.list:deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main t0p@pluto:~$ cd /etc/apt/sources.list.d/ t0p@pluto:/etc/apt/sources.list.d$ ls <snip> google-cloud-sdk.list <snip> t0p@pluto:/etc/apt/sources.list.d$ cat google-cloud-sdk.list deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.