Commit Graph

137 Commits

Author SHA1 Message Date
Martchus 22aa2f0851 Handle TRACKTOTAL/DISCTOTAL/PARTTOTAL fields in Vorbis Comments
See the corresponding tagparser commit
2024-02-28 21:39:52 +01:00
Martchus 2cd47777a3 Add mapping for "Publisher webpage" in CLI 2024-01-04 20:54:43 +01:00
Martchus 72dcbbbd81 Allow renaming file via `set --script …`
This allows doing what the GUI renaming utilitiy does on the command-line.
If only renaming is wanted
2023-11-10 15:46:45 +01:00
Martchus e58f8a14a5 Make setting covers via CLI work with Windows drive letters
Interpret a single letter plus colon as drive specification followed by the
actual path instead of splitting it and considering the path the cover
type.

See https://github.com/Martchus/tageditor/issues/109
2023-08-09 23:54:01 +02:00
Martchus f4346fb8e6 Allow preserving the muxing/writing application
See https://github.com/Martchus/tageditor/issues/108
2023-08-09 23:27:34 +02:00
Martchus 1cb00c7c41 Rename `mediafileinfoobject.cpp` to `scriptapi.cpp`
The file contains various wrapper "objects" so it makes sense to use a more
generic name.
2023-08-09 22:38:02 +02:00
Martchus 488684a318 Show muxing/writing application when displaying file info 2023-08-08 17:24:37 +02:00
Martchus c4f7d195a0 Allow adding cover via JavaScript 2023-08-07 18:41:19 +02:00
Martchus d248c63279 Allow passing settings to JavaScript 2023-08-07 17:30:25 +02:00
Martchus 9aca90538d Execute JavaScript after tags have been added/removed 2023-08-02 17:42:47 +02:00
Martchus 22953ad0da Allow tag processing via JavaScript 2023-07-30 16:15:19 +02:00
Martchus a6231b8442 Add the tag type the "not supported for" message refers to 2023-05-03 21:09:36 +02:00
Martchus 0e36eec6c7 Suppress "field not supported" for ID3v1 fields if writing ID3v2 as well 2023-05-03 21:00:59 +02:00
Martchus b7016f98a2 Add pedantic argument to allow returning a non-zero exit code in case of errors
This is especially useful to check whether a file is complete, e.g. one might
use `tageditor info --validate --pedantic --files …` to check whether the
specified files are ok. (If they were truncated there's be an error about it
and the command would return a non-zero exit code. Without pedantic this would
just return in a non-zero exit code if the file couldn't be parsed at all.)
2023-04-25 23:16:15 +02:00
Stent 3fe8db2c01
Fix language mistakes in cli help text
Closes #96
2022-12-22 13:37:08 +00:00
Martchus 08629ef4ee Improve error handling when setting tags in CLI 2022-08-12 00:28:57 +02:00
Martchus b26b972e25 Return non-zero exit code in all fatal error cases
See https://github.com/Martchus/tageditor/issues/83
2022-05-21 13:06:34 +02:00
Martchus 56ca398dda Apply changes to any Ogg Vorbis comment unless a track has been specified
This is required since the parsed Ogg Vorbis comment's target is set to the
containing Ogg stream as it still makes sense not having to care about the
specific track in most cases.
2022-05-04 00:42:48 +02:00
Martchus 5e808d069b Support many more fields 2022-04-06 01:15:21 +02:00
Martchus a40cff17a9 Apply clang-format 2022-04-05 20:17:33 +02:00
Martchus 32c9cbaae2 Use `makeNativePath()` instead of `u8path()`
On non-Windows platforms the internal representation used for paths is the
configured native (narrow) character set. Most of the time that's UTF-8 but
only on Windows UTF-8 is *always* used for the internal representation.
2022-03-17 22:41:51 +01:00
Martchus 30bf73163f cli: Catch conversion exceptions when making tag values from CLI args 2022-03-16 21:09:20 +01:00
Martchus df1c949f88 cli: Revamp `extract` to allow specifying index of value to extract 2022-03-16 20:37:35 +01:00
Martchus 7f1e234f36 Fix occurrences of wrong encoding handling with `std::filesystem` 2022-03-16 19:51:54 +01:00
Martchus ef637cb361 Use more uniform coding style in `setTagInfo()` 2022-01-01 20:45:06 +01:00
Martchus 28691378ce Avoid creation of targets when relevat values are empty or when using relaxed matching 2022-01-01 20:44:42 +01:00
Martchus dca5905744 Improve coding style in CLI code
* Use `std::string_view` instead of `const std::string &`
* Use `const` and `auto` where it makes sense
2021-12-31 00:41:56 +01:00
Martchus c71fde86ec Allow relaxed target matching 2021-12-31 00:40:36 +01:00
Martchus 34282ebbe9 Remove handling for comma-separated specifications of targets to remove 2021-12-31 00:35:42 +01:00
Martchus c753c2e1fd Remove unused variable 2021-12-05 17:52:55 +01:00
Martchus 43ebafe6dc Improve error message when trying to assign attachments to format not supporting it
See https://github.com/Martchus/tageditor/issues/74
2021-09-24 21:54:52 +02:00
Martchus fef97aa1db Allow specifying `--validate` flag when displaying file info 2021-08-18 23:12:27 +02:00
Martchus 33b346fb7e Improve error message when file for tag value not found 2021-08-14 14:23:08 +02:00
Martchus 9c1bd4c210 Avoid warning about implicit conversion 2021-07-03 23:53:20 +02:00
Martchus b4d1df8592 Fix typos found via `codespell --skip .git -w` 2021-07-03 19:38:36 +02:00
Martchus a9f3a607a3 Improve showing IO errors
* Make error messages and dialogs more consistent
* Print the actual error message (which might actually contain something
  useful when NativeFileStream is used)
2021-06-01 22:36:48 +02:00
Martchus 523971ad9d Suppress warning about cover type for ID3v1 tag when also an ID3v2 tag is present 2021-06-01 22:05:07 +02:00
Martchus 7ada28b06e cli: Allow preserving the modification time
See https://github.com/Martchus/tageditor/issues/66
2021-06-01 21:56:23 +02:00
Martchus 3203d4403e Apply clang-format 2021-05-27 18:56:53 +02:00
Martchus 9e0ce80c8c cli: Add --quiet flag to set operation 2021-05-27 18:56:42 +02:00
Martchus 53f0f02c72 Fix handling arbitrary files specified as field values
The container offset must not be used here as it may be garbage if the file
format is not recognized (e.g. if the file is an arbitrary text file).
2021-05-22 23:02:55 +02:00
Martchus 54093af53b Add missing include for std::optional 2021-05-22 22:59:52 +02:00
Martchus 1944773022 Allow setting multiple covers of the same type but different descriptions
The standard actually says that there might be different covers with only
different descriptions:

    Description is a
    short description of the picture, represented as a terminated
    text string. There may be several pictures attached to one file, each
    in their individual "APIC" frame, but only one with the same content
    descriptor. There may only be one picture with the picture type
    declared as picture type $01 and $02 respectively.

I assume "content descriptor" means combination of the type and
description.

This is in accordance with eyeD3.

See https://github.com/Martchus/tageditor/issues/64#issuecomment-833952940
2021-05-10 20:51:15 +02:00
Martchus 41fb2069f3 Allow setting covers of special types with description via CLI
See https://github.com/Martchus/tageditor/issues/64
2021-04-28 00:57:57 +02:00
Martchus d31fd79e87 Adapt to changes in tagparser library 2021-04-23 22:18:30 +02:00
Martchus e535e20720 Fix warnings 2021-03-20 21:59:49 +01:00
Martchus 9fbb375924 Adapt to changes in tagparser (without making actually use of the new API) 2021-02-04 23:22:43 +01:00
Martchus 82d0834e75 Adapt to changes in tagparser 2021-02-02 11:02:30 +01:00
Martchus 670a9a1c91 Adapt to changes in tagparser 2021-01-30 21:57:09 +01:00
Martchus 0a7d05256c Adapt to changes in tagparser v10 2020-12-14 21:19:49 +01:00