everything related to duct tape audio suite (dtas)
 help / color / mirror / code / Atom feed
Search results ordered by [date|relevance]  view[summary|nested|Atom feed]
thread overview below | download mbox.gz: |
* [ANN] dtas 0.18.1 - duct tape audio suite for *nix
@ 2021-02-13 21:59  4% Eric Wong
  0 siblings, 0 replies; 2+ results
From: Eric Wong @ 2021-02-13 21:59 UTC (permalink / raw)
  To: dtas-all, ruby-talk

Free Software command-line tools for audio playback, mastering, and
whatever else related to audio.  dtas follows the worse-is-better
philosophy and acts as duct tape to combine existing command-line tools
for flexibility and ease-of-development.  dtas is currently implemented
in Ruby (and some embedded shell), but may use other languages in the
future.

Changes:

    Mainly seek improvements to dtas-player.  The fallback to use
    charlock-holmes for strangely-encoded files is fixed.

    7 changes since 0.18.0 (2020-02-03):

          splitfx: reduce syscalls for writing comments file
          splitfx: support --err-suffix option
          player: fix +/- directional seeks while paused
          README: update and add more URLs for archives
          encoding: use CharlockHolmes properly on first run
          dtas-console: gracefully handle seek failures
          INSTALL: update dependencies for current Debian stable

* homepage: https://80x24.org/dtas/
* https://80x24.org/dtas/INSTALL
* https://80x24.org/dtas/dtas-player.txt
* https://80x24.org/dtas/NEWS.atom
* git clone https://80x24.org/dtas.git
* dtas-all@nongnu.org (plain-text only, no HTML mail, please)
* mail archives: https://80x24.org/dtas-all/
  nntps://news.public-inbox.org/inbox.comp.audio.dtas
  imaps://anon:mous@public-inbox.org/inbox.comp.audio.dtas.0
  nntp://ou63pmih66umazou.onion/inbox.comp.audio.dtas
  imap://anon:mous@ou63pmih66umazou.onion/inbox.comp.audio.dtas.0
  https://80x24.org/dtas-all/new.atom

note: .onion URLs require Tor: <https://www.torproject.org/>


^ permalink raw reply	[relevance 4%]

* [PATCH] encoding: use CharlockHolmes properly on first run
@ 2020-09-29  2:31  7% Eric Wong
  0 siblings, 0 replies; 2+ results
From: Eric Wong @ 2020-09-29  2:31 UTC (permalink / raw)
  To: dtas-all

Ruby case/when is not like C with fall-through, so we can't
rely on fall-through behavior to use CharlockHolmes to detect
legacy encodings.
---
 lib/dtas/encoding.rb | 15 +++++++--------
 1 file changed, 7 insertions(+), 8 deletions(-)

diff --git a/lib/dtas/encoding.rb b/lib/dtas/encoding.rb
index dad54af..bbc6076 100644
--- a/lib/dtas/encoding.rb
+++ b/lib/dtas/encoding.rb
@@ -11,15 +11,14 @@ def self.extended(mod)
 private
 
   def try_enc_harder(str, enc, old) # :nodoc:
+    begin
+      require 'charlock_holmes'
+      @charlock_holmes = CharlockHolmes::EncodingDetector.new
+    rescue LoadError
+      @charlock_holmes = false
+    end if @charlock_holmes.nil?
+
     case @charlock_holmes
-    when nil
-      begin
-        require 'charlock_holmes'
-        @charlock_holmes = CharlockHolmes::EncodingDetector.new
-      rescue LoadError
-        warn "`charlock_holmes` gem not available for encoding detection"
-        @charlock_holmes = false
-      end
     when false
       enc_fallback(str, enc, old)
     else


^ permalink raw reply related	[relevance 7%]

Results 1-2 of 2 | reverse | options above
-- pct% links below jump to the message on this page, permalinks otherwise --
2020-09-29  2:31  7% [PATCH] encoding: use CharlockHolmes properly on first run Eric Wong
2021-02-13 21:59  4% [ANN] dtas 0.18.1 - duct tape audio suite for *nix Eric Wong

Code repositories for project(s) associated with this public inbox

	https://80x24.org/dtas.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).