1

Is there some shell script out there that will update my files for me?

# apt update Notice: Missing Signed-By in the sources.list(5) entry for 'https://storage.googleapis.com/cros-packages/133' Notice: Missing Signed-By in the sources.list(5) entry for 'http://opensource.nchc.org.tw/debian' Notice: Consider migrating all sources.list(5) entries to the deb822 .sources format Notice: The deb822 .sources format supports both embedded as well as external OpenPGP keys Notice: See apt-secure(7) for best practices in configuring repository signing. 

I have spent hours trying to figure out this out and just give up.

My files just have "deb ..." lines in them.

And here is

$ cd /usr/share/keyrings && ls cros.gpg debian-archive-bullseye-stable.gpg debian-archive-bookworm-automatic.gpg debian-archive-buster-automatic.gpg debian-archive-bookworm-security-automatic.gpg debian-archive-buster-security-automatic.gpg debian-archive-bookworm-stable.gpg debian-archive-buster-stable.gpg debian-archive-bullseye-automatic.gpg debian-archive-keyring.gpg debian-archive-bullseye-security-automatic.gpg debian-archive-removed-keys.gpg 

Also I filed https://issues.chromium.org/issues/392237686 because shouldn't /etc/apt/sources.list.d/cros.list be the chrome team's responsibility to update, not mine?

2
  • Please edit your question and clarify. What is the actual problem here? The issue you link to has no information at all, and the question here is only slightly less vague. What OS are you using? Please add that to the question, not as a tag. And you have tagged with both chrome-os and debian, so which one are you actually using? And is there a problem or do you just not want to see those notices? Commented Jan 25 at 17:20
  • Nagging warnings in sid. But my script below fixed them! Commented Jan 26 at 9:39

2 Answers 2

1

I finally did it! Here's my script. Run it on a sources.list file:

#!/usr/bin/perl use strict; use warnings q!all!; my $n = "narflowitz"; #example while (<>) { chomp; if (/^deb/) { die "$0: Sorry, can't deal with [options] yet." . " P.S., don't hold your breath." if /\[/; my @m = split; printf "$/#Was: $_$/Types: %s$/URIs: %s$/Suites: %s" . "$/Components: %s$/Signed-By: %s$/$/", @m[ 0 .. 2 ], qq(@m[3..$#m]), q(/usr/share/keyrings/debian-archive-keyring.gpg); } } print "Tweak and put the above into a new file: /etc/apt/sources.list.d/$n.sources . /etc/apt/sources.list.d/$n.list is the old file that should be removed. "; 

And here's the output:

#Was: deb http://opensource.nchc.org.tw/debian/ unstable main contrib non-free non-free-firmware Types: deb URIs: http://opensource.nchc.org.tw/debian/ Suites: unstable Components: main contrib non-free non-free-firmware Signed-By: /usr/share/keyrings/debian-archive-keyring.gpg Tweak and put the above into a new file. E.g.,: /etc/apt/sources.list.d/narflowitz.sources . /etc/apt/sources.list.d/narflowitz.list is the old file that should be removed. 
1

Why in the world bother making your own scripts when you can just do

# apt modernize-sources The following files need modernizing: - /etc/apt/sources.list.d/google-chrome-beta.list - /etc/apt/sources.list.d/google-earth-pro.list - /etc/apt/sources.list.d/jidanni.list Modernizing will replace .list files with the new .sources format, add Signed-By values where they can be determined automatically, and save the old files into .list.bak files. 

Sounds scary.

Fear not.

For a simulation, respond N in the following prompt. Rewrite 3 sources? [Y/n] N Simulating only... 

Why didn't you tell us earlier? That would be more productive, you know.

They just added it.

You must log in to answer this question.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.