about summary refs log tree commit homepage
path: root/bin
DateCommit message (Collapse)
2024-02-01dtas-splitfx: add --stats/-S switch HEAD master
Similar to the switch in dtas-archive(1), I got tired of having to manually add stats to all the rips I was tracking out.
2023-07-03dtas-tl: reto: force ASCII-8BIT regexp match
POSIX path names aren't guaranteed to be UTF-8, and dtas should be capable of playing non-UTF-8 path names from read-only legacy FSes.
2023-07-03dtas-tl: speed up prune by pipelining requests
We are safely be able to pipeline 10 requests via SOCK_SEQPACKET on any OS without hitting buffering limits.
2023-07-03dtas-tl: reduce syscalls to speedup `reto' subcommand
Syscalls and waiting for responses are expensive, so grab 128 track IDs at once like we do for other subcommands.
2023-07-03dtas-archive: support -m/--match=REGEXP switch
Sometimes I only want to archive files matching a certain regexp pattern.
2022-11-24dtas-tl edit: do not shell-escape text file
There's no need to shell-escape the text file in most cases, so make the display of non-ASCII characters more pleasant to users with UTF-8-capable terminals and editors.
2022-01-27readahead: do not call -@ on non-String
There may not be an `infile' element in the `current' response. Fixes: bf9787ac517fe19a ("deduplicate and freeze pathnames + metadata")
2022-01-24splitfx: add --filter option to limit match to comments
This can allow filtering for tracks with a given comment declared via the ".#{COMMENT}" mechanism or the track title. If no prefix is given (before the '='), then all comment values are matched.
2022-01-23do not check IO#closed? before calling IO#close
IO#close is idempotent since Ruby 2.3, so reduce our instruction footprint to save some memory.
2022-01-23use IO#wait_readable consistently
Since Ruby 2.3, it no longer checks FIONREAD, and we require Ruby 2.3+ nowadays, so drop our IO.select-based workarounds.
2022-01-23dtas-tl: drop encoding hacks, use binary stdout+stderr
Try to consistently treat pathnames as binary blobs everywhere, since POSIX FSes allow everything but "\0" in pathnames.
2022-01-23dtas-tl prune: cull missing files from tracklist
This helps for folks creating and replacing many throwaway files while editing with dtas-splitfx, or compulsive renamers.
2022-01-21dtas: drop unnecessary "require 'yaml'" statements
We use DTAS.yaml_load to wrap all YAML.*load calls, but we still need "require 'yaml'" for various .to_yaml calls.
2022-01-21deduplicate and freeze pathnames + metadata
This ought to save some memory for dtas-player and dtas-readahead users with multiple instances of the same track(s) on their track list.
2022-01-21use YAML.unsafe_load in Psych 4.x (Ruby 3.1+)
Psych 4.x defaults to "nanny mode" to handle untrusted data. This causes breakage with since YAML references (aliases) emitted by dtas-player can't be handled by Psych clients under Ruby 3.1. Since dtas is single user and is a shell designed to run arbitrary code, favor the new YAML.unsafe_load API which behaves like the old YAML.load in Ruby <= 3.0.
2022-01-21require Ruby 2.3+
This allows us to jettison a bunch of compatibility code since we've started using Etc.nprocessors and String#- (uminus) in more places. The Ruby core team doesn't support <= 2.5, even.
2022-01-16console: workaround safe warnings in outdated `curses' gem
Debian bullseye users are stuck with ruby-curses 1.2.4, which means they'll hit rb_safe_level warnings with Ruby 2.7+. cf. https://bugs.debian.org/958973
2022-01-11dtas-console: support Wayland terminal titles, too
Tested-by: James Rowe <jnrowe@gmail.com>
2022-01-11dtas-console: add 'i' toggle to show comments (metadata)
This can be useful in the face of non-descriptive filenames.
2022-01-11dtas-console: set X11 terminal title iff DISPLAY is set
This allows users running terminals in graphical environments to navigate to the terminal running dtas-console more easily.
2022-01-11splitfx: use Etc.nprocessors for jobs if unspecified
We'll take advantage of multicore if available; because even bums like me have SMP machines these days.
2022-01-11archive: support comments, default to none
The default "Processed by SoX" comment is pointless, and I often want to archive + tag something in one step to reduce FS I/O.
2021-02-13dtas-console: gracefully handle seek failures
dtas-console doesn't need to quit when a user attempts to seek an unseekable file, since the user often doesn't know it's unseekable until a seek is attempted.
2020-04-20splitfx: support --err-suffix option
Write the contents of "stderr". This is useful for capturing the per-track output of the sox(1) "stats" effect when combined with parallel "--jobs".
2020-02-03doc: update copyrights for 2020
Using the 'update-copyright' script from gnulib[1]: git ls-files | UPDATE_COPYRIGHT_HOLDER='all contributors' \ UPDATE_COPYRIGHT_USE_INTERVALS=2 \ xargs /path/to/gnulib/build-aux/update-copyright [1] https://git.savannah.gnu.org/git/gnulib.git
2019-11-13readahead: avoid Array#compact and Array#max on `false'
seek_to_cur_pos needs to return `nil', not `false' on dead processes when monitoring processes for readahead.
2019-11-02dtas-console: pass kwargs as-is to String#encode
Ruby 2.7.0dev will warn when hashes are passed and intended for use as kwargs unless we expand the hash via "**enc_opts", but "**" is Ruby 2.0+ syntax and I guess we still support 1.9.3 for the time being.
2019-11-02dtas-console: remove unused variables
"ruby -w" will warn on them
2019-01-02dtas 0.16.0 v0.16.0
A bunch of minor fixes and cleanups accumulating for the past two years since the last release. It's tough to remember to make releases when I'm always running the latest version from git :x Most notably, "io_splice" is no longer used for dtas-linux users since "sleepy_penguin" includes all the functionality we use. This is to reduce memory overhead from extra DSOs(*) There's also some deprecation warning fixes for the still-undocumented "dtas-mlib" command. 12 changes since v0.15.0 (2017-04-07): pipeline: new module for running process pipelines console: ensure time calculations are done in UTC Rakefile: update path for uploads player: support guessing encodings for comments get rid of Windows-31J regexps mlib: compatibility with Sequel 5.x mlib: remove redundant tag massaging and encoding mlib: use flock to get around SQLite busy errors mlib: ignore files with nil times dtas/watchable: check SystemCallError mlib: fix unused variable warning use sleepy_penguin 3.5+ for splice and tee support (*) https://udrepper.livejournal.com/8790.html
2018-01-29get rid of Windows-31J regexps
Oops, a Perlism crept in :x
2017-11-19console: ensure time calculations are done in UTC
We must do this if the user does not use UTC in their time zone, otherwise things could get a bit wacky in the display.
2017-01-17readahead: fix running commands with non-files
2017-01-13readahead: handle queued commands properly (again)
We may have hashes in the queue, too. Followup-to: af91a075c10c ("readahead: handle queued commands properly")
2016-12-27http -> https, and relocate homepage to https://80x24.org/dtas/
HTTPS allows some level of security(*) and we've actually supported it on 80x24.org for many months, now. So, point new readers to it. Moving away from hostname-based homepages will allow us to save on subjectAltName space (and bandwith) when negotiating an HTTPS connection. We'll also have an .onion mirror for Tor users, soon, too; in case we can't afford to pay ICANN in the future. (assuming TLS libraries don't have any more Heartblead-level bugs in them, CAs aren't compromised, MITM HTTPS stripping proxies don't get in your way, and your certificate bundle isn't compromised).
2016-11-05readahead: handle queued commands properly
We can't do much for readahead when it comes to dtas-player running arbitrary commands.
2016-07-07dtas-readahead: cleanup open files on pause
We must not leave open files lingering when the player pauses, as it could prevent remote filesystems from unmounting.
2016-06-17archive: fix suffix replacement for stats
We should generate "XYZ_0001.stats" files, not "XYZ_0001.flac.stats".
2016-02-12dtas-readahead: do not barf on missing ffprobe/avprobe
Both of these are optional, so stop trying them if we do not detect them.
2016-01-25player: support "consume" mode for tracklist
When activated, this boolean deletes a song from the tracklist after it is played.
2016-01-25mlib: support --force option
We will allow forcing updates since upgrading dependent software (e.g. sox, avprobe, ffprobe) may allow previously-ignored files to become support
2016-01-21dtas-tl: fix "cat" output
It needs to display the track ID on the left like in 0.13.0 and earlier versions. Oops. Fixes: cb5a016bf5e1 ("dtas-tl: shell-unescape cat output")
2016-01-17dtas-mlib: avoid redundant '/' in dumped pathname
Harmless, but noisy and ugly.
2016-01-17dtas-tl: shell-unescape cat output
We do the same with edit and this makes tracklists look nicer with non-7-bit-ASCII characters. While we're at it, use each_slice to request more info from the tracklist to reduce syscalls on both ends.
2016-01-17dtas-tl: hopefully fix up encoding issues
POSIX filesystems allow any combination of bytes, so we should be able to edit the tracklist when we have a filename with non-UTF-8 (or whatever locale the user uses). Try to present the user with a reasonable name when they have an external encoding (typically UTF-8); but be prepared to dump out whatever binary sequence the filesystem allows.
2016-01-05console: show tracklist shuffle status, too
We support this feature, so it should probably be shown along with the repeat status of the tracklist. Ensure we notify all of our listeners about the status change in player, too.
2016-01-04console: try harder to show rate
Try to take advantage of bypass being enabled for sample rate, then show the raw sample offset if we cannot get the rate.
2016-01-02copyright updates for 2016
Using the 'update-copyright' script from gnulib[1]: git ls-files | UPDATE_COPYRIGHT_HOLDER='all contributors' \ UPDATE_COPYRIGHT_USE_INTERVALS=2 \ xargs /path/to/gnulib/build-aux/update-copyright [1] git://git.savannah.gnu.org/gnulib.git
2016-01-01console: display paused commands properly
Running commands can be "paused" (actually, they're stopped), so we must display them correctly when attempting to encode them in the correct format instead of barfing when we attempt to call the 'encode' method on a Hash object.
2015-12-31dtas-console: show trim and "tl repeat" status
It probably makes sense for the -console user to know if tracklist repeat and trim are enabled. Have player emit these in "current" output and let the console client track them for now.
2015-12-31dtas-console: show paused track and time offset
When invoking the "current" command, the player now returns the first track + offset in the queue. This should make it easier to show what's paused or not.