diff options
author | Timo Teras <timo.teras@iki.fi> | 2009-11-06 11:31:03 +0200 |
---|---|---|
committer | Timo Teras <timo.teras@iki.fi> | 2009-11-06 11:31:03 +0200 |
commit | a93a35eecaf580d97f6a451d7e951be0ff18372c (patch) | |
tree | cec5984f85821ad8aff5cfe317e98c0e5f4ab36e /src/apk.c | |
parent | 44ac0b06af20bd32010502a10d8bb7752215c627 (diff) | |
download | apk-tools-a93a35eecaf580d97f6a451d7e951be0ff18372c.tar.gz apk-tools-a93a35eecaf580d97f6a451d7e951be0ff18372c.tar.bz2 apk-tools-a93a35eecaf580d97f6a451d7e951be0ff18372c.tar.xz apk-tools-a93a35eecaf580d97f6a451d7e951be0ff18372c.zip |
apk: add --never-overwrite flag (ref #197)
to never ever overwrite a while in the filesystem the user knows
about. it gives the impression of extraction succeeding even though
nothing was done. this is inteded to be used only for bootstrapping
with overlay.
Diffstat (limited to 'src/apk.c')
-rw-r--r-- | src/apk.c | 4 |
1 files changed, 4 insertions, 0 deletions
@@ -57,6 +57,7 @@ static struct apk_option generic_options[] = { { 0x108, "repositories-file", "Override repositories file", required_argument, "REPOFILE" }, { 0x109, "no-network", "Do not use network (cache is still used)" }, + { 0x110, "never-overwrite", "Never overwrite existing files" }, }; const char *apk_error_str(int error) @@ -384,6 +385,9 @@ int main(int argc, char **argv) case 0x109: apk_flags |= APK_NO_NETWORK; break; + case 0x110: + apk_flags |= APK_NEVER_OVERWRITE; + break; default: if (applet == NULL || applet->parse == NULL || applet->parse(ctx, &dbopts, r, |