1
0
Fork 0
mirror of https://github.com/pygos/pkg-utils.git synced 2024-11-22 21:09:47 +01:00
Commit graph

36 commits

Author SHA1 Message Date
4141e666b6 Move file compressors details from command line to desc file instead
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-08 11:20:12 +01:00
95c7302d25 Allow empty packages, i.e. packages not containing any files
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-08 11:20:12 +01:00
d55ee9bd72 Add a toc format that is also valid input for pkg pack
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 18:52:11 +01:00
27c802fed0 Cleanup/fix order of toc entries
- Make sure we always sort the list when reading it from a package
 - Cleanup and clarify order of elements

Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 18:08:32 +01:00
16bf7172fe Add support for device special files in packages
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 17:57:10 +01:00
6f32c6b883 Add flag to surpress creation of symlinks when unpacking
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 16:26:47 +01:00
deb7bb0d4e Cleanup automakefile structure
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 15:51:55 +01:00
6a80140c59 Move abstract file list handling code to seperate utility library
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 15:39:43 +01:00
4d8b8f52d5 Split utility code up into translation-unit per function
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 15:29:16 +01:00
16f3e4d97c Move utility source code to libuitil.a
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 15:26:31 +01:00
618aaf4278 Make sure toc printers and IDs are propperly assigned
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-04 15:12:06 +01:00
8754729cb1 Improve unpack error handling, ignore mkdir failure on EEXIST
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-03 16:18:34 +01:00
dd6022b686 optarg fixup
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-03 15:02:37 +01:00
391e69eceb Fix mkdir_p for absolute directories
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-03 15:02:37 +01:00
c23a2c8c33 Add listing modes to install command
Allow the install command to either list the packages it wants to install,
or to list the files it would install.

Optionally allow the command to ignore dependencies.

Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-03 15:02:37 +01:00
c800554979 Fix argument requirements in unpack command line switches
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-03 15:02:37 +01:00
26a7d3f3e7 Add install command
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-03 15:02:37 +01:00
3298ca1a73 Help text fixups
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-02-02 20:31:38 +01:00
effe7bf69a pack: If source path is omitted, interpret as relative path
If no source file path is given for the file statement in a package source
listing, take the actual file name and interpret it as relative to the
source listing file.

Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-31 23:23:05 +01:00
a32a4cb149 Cleanup: unify input file processing code
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-31 22:15:41 +01:00
6fc871b3ff Move input file processor to main code
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-31 17:56:29 +01:00
134458b85a file processing: remove trailing spaces from line
Such as a line feed left there by getline().

Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-31 17:50:49 +01:00
417fa5b907 Cleanup: remove unpack.h, eliminate subdirectory
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-30 13:48:58 +01:00
f62bab2629 Move pkg unpack functionality out of unpack command
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-30 13:26:05 +01:00
b052a12beb unpack: rename flags
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-30 13:08:14 +01:00
35fabedb49 Move package unpacking functionality to generic pkg_unpack function
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-30 13:02:06 +01:00
be9bfed9b0 Add header for high-level package I/O functions
Mov file list from package function into seperate module, move declaration
into new high-level header.

Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-30 11:34:23 +01:00
3a4f19d1c5 unpack: don't chdir use dirfd, cleanup permissions
- don't chdir into root directory, use dirfd instead
 - make sure we don't dereference symlinks when chaning permissions
   (using appropriate AT_* flag)

Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-30 11:27:32 +01:00
04f19bac2f pack: read package name from description
This commit changes the pack command to read the output package name from
the description file instead of the command line. The command line argument
is replaced with a package repository directory to which the package file
is then written.

Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-30 10:40:02 +01:00
9b18455679 pack: close the input file after reading the package description
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-30 10:39:12 +01:00
e3740ba387 Move mkdir_p helper function to main code
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-29 22:03:33 +01:00
09a336507d Add flags to dump command to dump header data vs file list
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-29 00:14:06 +01:00
aab510aa98 Add package header with dependency information
Signed-off-by: David Oberhollenzer <goliath@infraroot.at>
2019-01-28 20:01:36 +01:00
David Oberhollenzer
47e237688b pack cmd: seperate file line reader from file list parser
Signed-off-by: David Oberhollenzer <david.oberhollenzer@tele2.at>
2019-01-27 16:46:44 +01:00
David Oberhollenzer
53194aa2ac Add lzma compressor
Signed-off-by: David Oberhollenzer <david.oberhollenzer@tele2.at>
2019-01-27 00:43:05 +01:00
David Oberhollenzer
6ec11b532e Initial commit
Signed-off-by: David Oberhollenzer <david.oberhollenzer@tele2.at>
2019-01-26 23:19:21 +01:00