Give list of packages installed with apt a name
How can I give a list of packages installed via apt a name, eg. one that I could find with dpkg-query -W my-packages
or something similar? For example, call the group
build-essential checkinstall gparted ...
of packages my-packages
Rationale: I would like to be able to check if default groups of packages have been installed in my install scripts.
Running Ubuntu 18.04
apt 18.04 package-management dpkg
add a comment |
How can I give a list of packages installed via apt a name, eg. one that I could find with dpkg-query -W my-packages
or something similar? For example, call the group
build-essential checkinstall gparted ...
of packages my-packages
Rationale: I would like to be able to check if default groups of packages have been installed in my install scripts.
Running Ubuntu 18.04
apt 18.04 package-management dpkg
add a comment |
How can I give a list of packages installed via apt a name, eg. one that I could find with dpkg-query -W my-packages
or something similar? For example, call the group
build-essential checkinstall gparted ...
of packages my-packages
Rationale: I would like to be able to check if default groups of packages have been installed in my install scripts.
Running Ubuntu 18.04
apt 18.04 package-management dpkg
How can I give a list of packages installed via apt a name, eg. one that I could find with dpkg-query -W my-packages
or something similar? For example, call the group
build-essential checkinstall gparted ...
of packages my-packages
Rationale: I would like to be able to check if default groups of packages have been installed in my install scripts.
Running Ubuntu 18.04
apt 18.04 package-management dpkg
apt 18.04 package-management dpkg
asked Jan 8 at 22:59
jenesaisquoijenesaisquoi
15010
15010
add a comment |
add a comment |
2 Answers
2
active
oldest
votes
The equivs
package seems to do exactly what I wanted, very simply creating a .deb
file that can be installed and queried using dpkg-query
. See tutorial for walk-through.
add a comment |
Beside using a meta package I would use a variable:
$ packages="coreutils wget"
$ dpkg-query -W $packages
coreutils 8.28-1ubuntu1
wget 1.19.4-1ubuntu2.1
$ echo $?
0
Means everything is fine (1) means something is missing.
Find a list of missing packages:
$ packages="coreutils wget 0ad pkg1 nonexits"
$ dpkg-query -W $packages 2>&1 > /dev/null | rev | cut -f1 -d' ' | rev
0ad
pkg1
nonexits
1
useful alternatives, thanks! The negative is I wouldn't be able to simple check my bundles had been installed from different scripts later on.
– jenesaisquoi
Jan 8 at 23:49
Yeah, it would be messy... Then I guess meta-packages are your best shot.
– Ravexina
Jan 8 at 23:54
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1108150%2fgive-list-of-packages-installed-with-apt-a-name%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
2 Answers
2
active
oldest
votes
2 Answers
2
active
oldest
votes
active
oldest
votes
active
oldest
votes
The equivs
package seems to do exactly what I wanted, very simply creating a .deb
file that can be installed and queried using dpkg-query
. See tutorial for walk-through.
add a comment |
The equivs
package seems to do exactly what I wanted, very simply creating a .deb
file that can be installed and queried using dpkg-query
. See tutorial for walk-through.
add a comment |
The equivs
package seems to do exactly what I wanted, very simply creating a .deb
file that can be installed and queried using dpkg-query
. See tutorial for walk-through.
The equivs
package seems to do exactly what I wanted, very simply creating a .deb
file that can be installed and queried using dpkg-query
. See tutorial for walk-through.
answered Jan 8 at 23:26
jenesaisquoijenesaisquoi
15010
15010
add a comment |
add a comment |
Beside using a meta package I would use a variable:
$ packages="coreutils wget"
$ dpkg-query -W $packages
coreutils 8.28-1ubuntu1
wget 1.19.4-1ubuntu2.1
$ echo $?
0
Means everything is fine (1) means something is missing.
Find a list of missing packages:
$ packages="coreutils wget 0ad pkg1 nonexits"
$ dpkg-query -W $packages 2>&1 > /dev/null | rev | cut -f1 -d' ' | rev
0ad
pkg1
nonexits
1
useful alternatives, thanks! The negative is I wouldn't be able to simple check my bundles had been installed from different scripts later on.
– jenesaisquoi
Jan 8 at 23:49
Yeah, it would be messy... Then I guess meta-packages are your best shot.
– Ravexina
Jan 8 at 23:54
add a comment |
Beside using a meta package I would use a variable:
$ packages="coreutils wget"
$ dpkg-query -W $packages
coreutils 8.28-1ubuntu1
wget 1.19.4-1ubuntu2.1
$ echo $?
0
Means everything is fine (1) means something is missing.
Find a list of missing packages:
$ packages="coreutils wget 0ad pkg1 nonexits"
$ dpkg-query -W $packages 2>&1 > /dev/null | rev | cut -f1 -d' ' | rev
0ad
pkg1
nonexits
1
useful alternatives, thanks! The negative is I wouldn't be able to simple check my bundles had been installed from different scripts later on.
– jenesaisquoi
Jan 8 at 23:49
Yeah, it would be messy... Then I guess meta-packages are your best shot.
– Ravexina
Jan 8 at 23:54
add a comment |
Beside using a meta package I would use a variable:
$ packages="coreutils wget"
$ dpkg-query -W $packages
coreutils 8.28-1ubuntu1
wget 1.19.4-1ubuntu2.1
$ echo $?
0
Means everything is fine (1) means something is missing.
Find a list of missing packages:
$ packages="coreutils wget 0ad pkg1 nonexits"
$ dpkg-query -W $packages 2>&1 > /dev/null | rev | cut -f1 -d' ' | rev
0ad
pkg1
nonexits
Beside using a meta package I would use a variable:
$ packages="coreutils wget"
$ dpkg-query -W $packages
coreutils 8.28-1ubuntu1
wget 1.19.4-1ubuntu2.1
$ echo $?
0
Means everything is fine (1) means something is missing.
Find a list of missing packages:
$ packages="coreutils wget 0ad pkg1 nonexits"
$ dpkg-query -W $packages 2>&1 > /dev/null | rev | cut -f1 -d' ' | rev
0ad
pkg1
nonexits
answered Jan 8 at 23:47
RavexinaRavexina
32.3k1483113
32.3k1483113
1
useful alternatives, thanks! The negative is I wouldn't be able to simple check my bundles had been installed from different scripts later on.
– jenesaisquoi
Jan 8 at 23:49
Yeah, it would be messy... Then I guess meta-packages are your best shot.
– Ravexina
Jan 8 at 23:54
add a comment |
1
useful alternatives, thanks! The negative is I wouldn't be able to simple check my bundles had been installed from different scripts later on.
– jenesaisquoi
Jan 8 at 23:49
Yeah, it would be messy... Then I guess meta-packages are your best shot.
– Ravexina
Jan 8 at 23:54
1
1
useful alternatives, thanks! The negative is I wouldn't be able to simple check my bundles had been installed from different scripts later on.
– jenesaisquoi
Jan 8 at 23:49
useful alternatives, thanks! The negative is I wouldn't be able to simple check my bundles had been installed from different scripts later on.
– jenesaisquoi
Jan 8 at 23:49
Yeah, it would be messy... Then I guess meta-packages are your best shot.
– Ravexina
Jan 8 at 23:54
Yeah, it would be messy... Then I guess meta-packages are your best shot.
– Ravexina
Jan 8 at 23:54
add a comment |
Thanks for contributing an answer to Ask Ubuntu!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1108150%2fgive-list-of-packages-installed-with-apt-a-name%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown