1dpkg-name(1) dpkg suite dpkg-name(1)
2
3
4
6 dpkg-name - rename Debian packages to full package names
7
9 dpkg-name [option...] [--] file...
10
12 This manual page documents the dpkg-name program which provides an easy
13 way to rename Debian packages into their full package names. A full
14 package name consists of package_version_architecture.package-type as
15 specified in the control file of the package. The version part of the
16 filename consists of the upstream version information optionally
17 followed by a hyphen and the revision information. The package-type
18 part comes from that field if present or fallbacks to deb.
19
21 -a, --no-architecture
22 The destination filename will not have the architecture
23 information.
24
25 -k, --symlink
26 Create a symlink, instead of moving.
27
28 -o, --overwrite
29 Existing files will be overwritten if they have the same name as
30 the destination filename.
31
32 -s, --subdir [dir]
33 Files will be moved into a subdirectory. If the directory given as
34 argument exists the files will be moved into that directory
35 otherwise the name of the target directory is extracted from the
36 section field in the control part of the package. The target
37 directory will be «unstable/binary-architecture/section». If the
38 section is not found in the control, then no-section is assumed,
39 and in this case, as well as for sections non-free and contrib the
40 target directory is «section/binary-architecture». The section
41 field is not required so a lot of packages will find their way to
42 the no-section area.
43
44 Warning: Use this option with care, it is messy.
45
46 -c, --create-dir
47 This option can used together with the -s option. If a target
48 directory isn't found it will be created automatically.
49
50 Warning: Use this option with care.
51
52 -?, --help
53 Show the usage message and exit.
54
55 -v, --version
56 Show the version and exit.
57
59 DPKG_COLORS
60 Sets the color mode (since dpkg 1.18.5). The currently accepted
61 values are: auto (default), always and never.
62
63 DPKG_NLS
64 If set, it will be used to decide whether to activate Native
65 Language Support, also known as internationalization (or i18n)
66 support (since dpkg 1.19.0). The accepted values are: 0 and 1
67 (default).
68
70 Some packages don't follow the name structure
71 package_version_architecture.deb. Packages renamed by dpkg-name will
72 follow this structure. Generally this will have no impact on how
73 packages are installed by dselect(1)/dpkg(1), but other installation
74 tools might depend on this naming structure.
75
77 dpkg-name bar-foo.deb
78 The file bar-foo.deb will be renamed to bar-foo_1.0-2_i386.deb or
79 something similar (depending on whatever information is in the
80 control part of bar-foo.deb).
81
82 find /root/debian/ -name '*.deb' | xargs -n 1 dpkg-name -a
83 All files with the extension deb in the directory /root/debian and
84 its subdirectory's will be renamed by dpkg-name if required into
85 names with no architecture information.
86
87 find -name '*.deb' | xargs -n 1 dpkg-name -a -o -s -c
88 Don't do this. Your archive will be messed up completely because a
89 lot of packages don't come with section information. Don't do
90 this.
91
92 dpkg-deb --build debian-tmp && dpkg-name -o -s .. debian-tmp.deb
93 This can be used when building new packages.
94
96 deb(5), deb-control(5), dpkg(1), dpkg-deb(1), find(1), xargs(1).
97
98
99
1001.21.21 2023-02-25 dpkg-name(1)