HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
sandreas
m4b-tool
PHP2018–2025
sandreas / m4b-tool

m4b-tool

m4b-tool is a command line utility to merge, split and chapterize audiobook files such as mp3, ogg, flac, m4a or m4b

3Distinct people
30Mentions
0Explicit recommenders
1.6KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

m4b-tool is a command line utility to merge, split and chapterize audiobook files such as mp3, ogg, flac, m4a or m4b

GitHub

Where it is used

No documented product use has been verified yet.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 9–Nov 16 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/16/2026, 12:01:57 AM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year30 dated mentions

Observed mentions: 2018-06-20 18:04:29 UTC to 2025-08-10 11:12:32 UTC.

024682018-01-01 00:00:00 UTC to 2019-01-01 00:00:00 UTC (exclusive): 3 mentions; 3 submissions, 0 comments20182019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 6 mentions; 4 submissions, 2 comments2020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 3 mentions; 0 submissions, 3 comments20212022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 8 mentions; 0 submissions, 8 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 5 mentions; 0 submissions, 5 comments2024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2025

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20182018-01-01 00:00:00 UTC2019-01-01 00:00:00 UTC330
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC642
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC202
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC303
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC808
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC505
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC202
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC101

What Hacker News says

8 sources
Hey, I'm the author of m4b-tool[1] and tone[2]. The most important thing I learned about software development, is that the best software has a meaning to yourself and that you should use it yourself on a regular basis. m4b-tool is a tool to merge multiple audio files into the m4b audio book format. I hacked it together in a weekend in the language I knew best (PHP) and that probably was the worst for the job. All because there were no tools, that fitted my needs. After the first improvements I said to my self: Why not open source it, even if it is in a pretty crappy state? And the feedback was surprisingly good for a hackish script. And I learned A LOT from the community (e.g. how to implement something like multithreading in PHP or the simple fact that `cd -` goes back one directory in history). Another important thing I learned is, that
Read the rest
early shipping is good, but automatic deployment and versioning is nearly as important. Thats why I decided to invest some time and simply release `tone` based on git tags with github actions... that was a very good decision so far. So to conclude: Build something, that you use (and want to improve) yourself Ship early Go for auto-deployment / CI as soon as possible Do some "marketing" for high quality feedback (e.g. on hackernews) Cover your ass with automatic tests as soon as possible [1]: https://github.com/sandreas/m4b-tool [2]: https://github.com/sandreas/tone
In Ask HN: HN people who write meaningful software, how did you learn to program?
Sure, why not... so my pet project is basically for managing my audio files. There already is navidrome[1] and audiobookshelf[2]. They work great so far, but some minor details are kind of annoying... The first milestone will be providing a basic API for my files - the main components of this will be the database (postgres), the API (C# + swashbuckle + JsonApiDotNet + Websockets) and the file indexer (C# HostedService). All parts except the file indexer are pretty much done, but it is a critical component, because it has to be as fast and correct as possible. There are multiple approaches to index files... A best case scenario would be an "import" / "move" of files into a library or repository. That way you would be always up to date and always perfectly sorted. Unfortunately, an import would also be a big amount of work, because analysin
Read the rest
g the files and getting metadata from online sources is... lets say a huge project. And NOT getting metadata would mean, that I cannot move the files while another app manages the metadata. So I took another path - scanning an existing and well tagged library (that I manage with beets[3] for music and m4b-tool[4] / tone[5] for audio books). My current Idea is to have a file indexer that: - can run on multiple sources - runs one full index scan after starting the app - registers a filesystem watcher for every file source and reacts to events - To ensure, no filesource is blocking others, each source is processed by a fixed batch size and then move on the the next file source - If sources are modified (added, changed, deleted), there is a decision, what to do with already running indexers and registered file watchers (added just go to the queue, changed and deleted cancel already running tasks only for this source) - All files are hashed (content only) to ensure, a change of metadata or tags will not change the hash, and if a file is moved, it will recognize this and update instead of delete and insert The database will contain Tag-Values for every possible value. E.g. File.Location music/album/AC_DC/Back in Black/01 - Hells Bells.mp3 FileTag.Type Artist Tag.Value AC/DC That way I can add a fulltext index on the Tags.Value field containing a searchable value while maintaining the FileTag.Type for recommendations. Let's say I search for `AC/DC`, it will provide an auto-complete for all FileTags.Type values, that show a match + a generic one for searching ALL values: Artist: AC/DC FullText: AC/DC Searching for 2010 will show: Released: 2010 Title: 2010 FullText: 2010 because it contains matches in Releasedate and title. There may be a lot to optimize, but I think my current plan goes pretty well. Let me know what you think about this approach :-) [1]: https://www.navidrome.org/ [2]: https://www.audiobookshelf.org/ [3]: https://beets.io/ [4]: https://github.com/sandreas/m4b-tool/ [5]: https://github.com/sandreas/tone/
In Ask HN: What interesting problems are you working on?
Usually, for electronic devices I start with the Open Source Projects recommendations or first class support items... They usually have good hardware quality e.g. for a smartphone, I look at lineage devices first and then check out reviews for these, that work for me from looking at the specs. For your purpose, there is no such audio player, I know of. The best devices I know atm are: - iPod Nano 7th gen 16GB - Pro: Size, Bluetooth, UI - Con: Battery, Storage, Formats, req. iTunes, no Wifi / NFC, No Upgrades - iPod classic (mod with iFlash Quad and 2200mah battery + iKokkia Bluetooth) - Pro: Storage, Battery, UI, Hackable (kind of) - Con: Size, Formats, req. Itunes, No native Bluetooth/Wifi/NFC, No upgrades - Maybe you should think of RockBox to have more freedom - LG G5 H850 (optional with Bang & Olufsen Hifi-Pl
Read the rest
us module) + Audiobookshelf + Substreamer - Pro: Formats, Battery, Storage, Bluetooth/Wifi/NFC, Hackable - Con: Size, UI (I did not find a Server/App nearly as good as iPod) Let me cite my comment from https://news.ycombinator.com/item?id=32042780: I use m4b-tool[1], tone[2] and audiobookshelf[3] together with an LG G5 H850 smartphone[8] with Bang & Olufsen Hifi-Plus Module for Audio Only and I am pretty happy with this config. For Music I use Navidrome[5] and Substreamer App[7]. Maybe I'll try out Jellyfin[4] or maybe Plex[6], but I really don't wanna go closed source. I also thought about writing something self hosted in C# to have ONE solution for audiobooks, podcasts and music and started a small private project, but this will take a while until it is ready to release something... You may ask: Why an LG G5 H850? Well, its relatively small and cheap (about 50 - 80 bucks used) it has an audio Jack, USB-C, you can change the battery, it can hold up to 2TB microSD storage, has an HiFi Plus module for audio enthusiasts and a descent screen. Besides that it can run lineage os... Note: I'm the author of the first two projects :-) [1]: https://github.com/sandreas/m4b-tool [2]: https://github.com/sandreas/tone [3]: https://github.com/advplyr/audiobookshelf [4]: https://jellyfin.org/ [5]: https://www.navidrome.org/ [6]: https://www.plex.tv [7]: https://substreamerapp.com/ [8]: https://en.wikipedia.org/wiki/LG_G5
In Ask HN: How do you search for products / apps given a list of requirements?
I use m4b-tool[1], tone[2] and audiobookshelf[3] together with an LG G5 H850 smartphone[8] with Bang & Olufsen Hifi-Plus Module for Audio Only and I am pretty happy with this config. For Music I use Navidrome[5] and Substreamer App[7]. Maybe I'll try out Jellyfin[4] or maybe Plex[6], but I really don't wanna go closed source. I also thought about writing something self hosted in C# to have ONE solution for audiobooks, podcasts and music and started a small private project, but this will take a while until it is ready to release something... You may ask: Why an LG G5 H850? Well, its relatively small and cheap (about 50 - 80 bucks used) it has an audio Jack, USB-C, you can change the battery, it can hold up to 2TB microSD storage, has an HiFi Plus module for audio enthusiasts and a descent screen. Besides that it can run lineage os... Note:
Read the rest
In Ask HN: Is there a Calibre equivalent for Audio books?
> Correction, ID3 is a good start. ;) Id3v2 is ... much more. You're absolutely correct :-) > Unrelated, I like your project! Nice! Thanks for your feedback, you're welcome... > (I'm not entirely sure what your tool does that isn't done by the standard tagging tools id3, id3tool, id3v2... but that's NOT a criticism. I wrote my own multithreaded-resumable-forensic `dd` and a homegrown replacement for `tar` for instance) Not much really, it is just a tool that supports multiple platforms and multiple metadataformats all in one static binary AND supports chapters... it may be a bit more versatile and easy too use than existing tools. But that is opinionated. > wanted something HIGH performance for tunable and batchable splits, silence detection, merges, as well as automatic clustering (!). Those split/merge features, that, I'm guessing you'
Read the rest
re planning on implement by requiring ffmpeg _AND_ using another library just to wrap it? I'd do in native code and, as a result, performance would be orders of magnitude better. Yes, I plan to use `ffmpeg` for the first part, but also include `fdkaac` and maybe `sox` or other audio specialist tools to provide better audio. My plan is also to integrate a dependency downloader, that does not want you to install the dependencies yourself, but does everything for you. I'm the author of `m4b-tool`[1], which has also split, merge and silence detection, so I have a little experience in exactly this topic you are talking about (tone is planed as long term successor of m4b-tool, but this will take time). I will use a library called CliWrap[4] to integrate shell execution though, but do it multithreaded to provide more performance. > I don't use windows (at least, I'm not willing to use windows for any 'pro bono' work ;-) ) but if you were to write your tool in C or C++ instead, or perhaps... have a common API layer of sorts... If I understood this correctly: C# is not Windows-Only any more, and it is pretty fast on all platforms. It provides Ahead of Time Compilation and a so called self-contained binaries working without any C# runtime or VM... using github actions I provide a full featured monolitic executable binary, but I could also provide a library. C# is even capable of and using unmanaged code, writing drivers and embedded stuff, like RPi... I think it is not a bad language to start such a project, but at least the best I know well enough ;) > and actually enjoy, helping you out by "gifting" some fast and MUCH leaner solutions for any and all of the audio processing work It would really be nice to find some collaborators, thank you. There are some C# audio processing libraries out there (like NAudio[2] or cscore[3]), but currently windows only or pretty complex. We'll see... :-) This was very helpful. Thanks again. [1]: https://github.com/sandreas/m4b-tool [2]: https://github.com/naudio/NAudio [3]: https://github.com/filoe/cscore [4]: https://github.com/Tyrrrz/CliWrap
In Show HN: Tone v0.0.4 – now hackable command line audio tagger, any feedback?
My audio workflow is basically command line / self-hosted: - beets [1] for music tagging - m4b-tool [2] and tone [3] for audio books merging and tagging (Note: I'm the author of these) - iTunes and an iPod Nano 7g and iPod classic 2009 to listen "offline" (although audiobookshelf supports offline downloads) - self-hosted navidrome [4] + substreamer[5] for music and audiobookshelf [6] for audio books on my android / ios devices Everything with docker containers without further dependencies. I must say, that this works pretty good so far and I never missed something really bad on id3v2.3 or mp4/m4b native tags. [1]: https://beets.io/ [2]: https://github.com/sandreas/m4b-tool/ [3]: https://github.com/sandreas/tone [4]: https://github.com/navidrome/navidrome [5]: https://substreamerapp.com/ [6]: https://www.audiobookshelf.org/
In What ID3v2 could have been
I usually tend to think over what I (personally) would expect the project to have / be. Nothing more, nothing less. That keeps me motivated. I started m4b-tool[1] for using it myself - and noticed, that the most features, I wanted it to have where not available in existing, free solutions. So I started to note things down, I would like to have for a utility to merge / create audio books. Now the project is a bit bloated and I learned so much on the way to its current state, that I'm thinking over rewriting it (not in RUST, but in C# ;) but it was a joyful journey with a lot of new ideas and experiences. Pro tip: Early shipping is very good for geetting early feedback and new ideas. Don't be afraid to publish something unpolished. [1] https://github.com/sandreas/m4b-tool/
In Ask HN: How do you start researching for a project idea?

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.