Commit Graph

13 Commits

Author SHA1 Message Date
benoitperrin 1abb470819 Fix adept_remove -O placing result in a nested sub-directory
With -O <dir>, the output path was built from the full input path
instead of its base name:

    filename = std::string(inputFile);
    if (outputDir)
        filename = std::string(outputDir) + "/" + filename;

So `adept_remove -O /out /tmp/x/book.epub` wrote the result to
/out/tmp/x/book.epub (createPath() silently creating the intermediate
directories) instead of /out/book.epub.

-O is documented as the directory "were to put result", so only the
input's base name should be appended. acsmdownloader is unaffected
because it derives its output name from the title metadata, not from
the input path.

Reduce the input to its base name before prefixing it with -O.
2026-07-01 11:14:30 +02:00
soutade b44b988966 Fix bug in utils with -o and -O options 2026-02-01 08:56:27 +01:00
soutade 8f0341d0bd Some code formating 2026-01-18 15:44:20 +01:00
soutade c259cbd5a3 Add missing libgen.h in utils for basename() call 2023-03-28 20:32:05 +02:00
soutade 3a0ab4b438 Update --help for utils and README.md 2023-01-08 21:04:23 +01:00
soutade 891ed05926 We can now specify directly file path for acsmdownloader and adept_remove (-f stille keeped for compatibility) 2023-01-08 20:58:41 +01:00
soutade ab5afa5003 Add new default ADEPT directories : /home/<user>/.config/adept and $ADEPT_DIR environment variable 2023-01-05 21:29:55 +01:00
soutade e4bd73c03d Add global option -D to utils, allowing to specify .adept directory instead of every single files. WARNING : -D has been changed by -d in adept_loan_mgt ! 2022-12-21 21:23:42 +01:00
soutade 7f5b787cb9 Add launcher util for AppImage 2022-08-29 11:56:47 +02:00
soutade 4f9b2de5a5 Remove use of tempnam function and fix bug (bad check of rename return) 2022-04-23 17:41:54 +02:00
soutade 2ce6142596 Remove QtCore and QtNetwork, replace them by libcurl + libc 2022-03-16 22:45:33 +01:00
soutade 0f475423c0 Add a private option into adept_remove to provide encryption key 2022-03-12 23:04:16 +01:00
soutade b8a4ca222e Add adept_remove util 2021-12-18 17:42:23 +01:00