Age | Commit message (Collapse) | Author | Files | Lines |
|
This prevents having unquoted expansion in the bsdcpio commandline
|
|
Not that it really matters, but let's scope this to where we actually
care for the modified time output.
|
|
Should have been removed as part of previous commit, as this was
clearly just a typo.
|
|
Reported in FS#38264.
|
|
This isn't documented, but it's needed since the kernel lz4 support is
based on the original streaming format and not the newer default. Use
-l to force the legacy codec.
Fixup lsinitcpio to support the older format, and, add a warning when
the newer format is detected. Who knows when this will be "resolved" ...
Upstream discussion: https://code.google.com/p/lz4/issues/detail?id=102
|
|
This essentially reverts 306dcbd7b21f8a680 which foolishly assumes that
kernel and libarchive decompression support stay in sync.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
The impetus for doing this was a bug in util-linux's hexdump which never
saw a release. For uniformity, simply echo an empty line here.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Note that this requires a very recent version of lz4 utilities as it
uses lz4, and not the original lz4c tool, in order to be command line
API compliant with other compression tools. See upstream discussions:
https://code.google.com/p/lz4/issues/detail?id=83
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
libarchive 3.1 supports LZO now, so we no longer need this indirection
everywhere.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
823e24 wasn't really correct, since running 'tput setaf 0' effectively
sanity checks the terminfo as well as checking existance. However, it
does nothing to affirm that the terminal is capable of supporting
colors.
Moreover, *never* fall back on the hardcoded escapes as doing so implies
that we've found a broken terminfo and we have no idea what the terminal
is capable of doing.
This reverts commit 823e2454176d4381cd3acc30481e9d84cdc298b1.
|
|
This leaves bash completion with a duplication, but this is intentional
to avoid pulling in the entire functions file and worrying about
pollution.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Specficially, abort when a user tries to run lsinitcpio on a kernel
image.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Pedantic, but at least this makes us consistent with mkinitcpio.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
FS#32605.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Eric Bélanger <snowmaniscool@gmail.com>
|
|
This is an ugly patch, and probably does more than I'd like it to. The
idea is that mkinitcpio adopts some sort of consistent style which I'm
actually happy with. I define 3 kinds of variables:
1) local variables: all lower case, and scoped within functions. Use
freely, as they're well contained.
2) global variables: these are known to mkinitcpio internally, but are
global in scope. They mainly carry runtime configuration and collected
data during the image generation process. These are always lower case,
but carry a leading underscore to denote that they're global.
3) "API" variables: also global in scope, but exist "outside" of
mkinitcpio -- either drawn in from the configuration file, or "exported"
to the install hooks. These are always all upper case. When introducing
new variables, extreme care must be taken to pick names that will not
conflict with the environment inherited by mkinitcpio.
A HACKING file is introduced with a similar description of the above,
and more.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
This is the default action for lsinitcpio. Add it just for the purpose
of clarity. This change also separates out true options from 'actions'
and validates that the user only passed a single action to lsinitcpio.
Update the manpage accordingly.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Now that mkinitcpio stores the build time config file in the image, we
should have a way of easily getting it back out.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
git (at least version 1.7.12.1) does a great job of showing the absolute
wrong code moving around in this patch.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
I almost deleted this, replacing it with only bsdtar. Add a comment so
I'm not tempted to do this again.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Show only regular files in /usr/bin instead of everything (including the
mess of symlinks to busybox and kmod). It's also a nice to have since
we're showing more about the multiple hook points now.
This mostly restores the behavior prior to f7b8a6f0fd.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Even for uncompressed images, estimate the work being done to extract to
ramfs.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Read this out of the image config for -a output.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
We read the image a number of times. Extract the image to a temp
directory so we can just extract it once and use the filesystem to our
advantage. This requires a temp dir which we can nuke on an EXIT trap,
but the whole operation is sped is a bit, especially for larger images.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
This only happens when the terminfo file is missing, but its a simple
fix.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Print a more helpful message when no image is specified.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Always display the file size on disk, but also display the uncompressed
size for compressed images. Borrows my own size_to_human function from
paccache and elsewhere.
Before:
==> Compressed with: gzip
-> Compression ratio: .377
-> Estimated decompression time: 0.058s
After:
==> Size: 2.67 MiB
==> Compressed with: gzip
-> Uncompressed size: 7.07 MiB (.377 ratio)
-> Estimated decompression time: 0.059s
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
mkinitcpio will always create /lib/modules/$kernver/kernel in the image,
so we can use this to detect the kernel the image was built for, even if
the image contains no modules.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
- trim leading paths from all binaries
- sort alphabetically
- add same trailing indent as the module display
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Report this version on -a if it's found.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Now that we're including symlinks to busybox on the prebuilt image, this
display needs a bit of tidying up.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
If the image we're pointing to is a symlink, show the resolution as part
of the name in -a's output.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
This was a copypasta error when taking this from makepkg, which has
special concerns in this regard. lsinitcpio should only concern itself
with stdout.
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
|
Signed-off-by: Dave Reisner <d@falconindy.com>
|