dtas 0.16.1 → 0.19.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -1
- data/Documentation/.gitignore +1 -1
- data/Documentation/GNUmakefile +2 -2
- data/Documentation/dtas-archive.pod +2 -2
- data/Documentation/dtas-console.pod +2 -2
- data/Documentation/dtas-ctl.pod +2 -2
- data/Documentation/dtas-cueedit.pod +2 -2
- data/Documentation/dtas-enq.pod +2 -2
- data/Documentation/dtas-env.pod +3 -3
- data/Documentation/dtas-msinkctl.pod +2 -2
- data/Documentation/dtas-player.pod +2 -2
- data/Documentation/dtas-player_effects.pod +2 -2
- data/Documentation/dtas-player_protocol.pod +4 -4
- data/Documentation/dtas-player_sink_examples.pod +2 -2
- data/Documentation/dtas-sinkedit.pod +4 -4
- data/Documentation/dtas-sourceedit.pod +4 -4
- data/Documentation/dtas-splitfx.pod +7 -1
- data/Documentation/dtas-tl.pod +4 -4
- data/Documentation/dtas-xdelay.pod +2 -2
- data/Documentation/update-footer.rb +2 -2
- data/GIT-VERSION-FILE +1 -1
- data/GIT-VERSION-GEN +2 -2
- data/GNUmakefile +13 -1
- data/HACKING +2 -2
- data/INSTALL +10 -24
- data/NEWS +103 -0
- data/README +14 -8
- data/Rakefile +1 -1
- data/TODO +3 -1
- data/bin/dtas-archive +1 -1
- data/bin/dtas-console +17 -21
- data/bin/dtas-ctl +1 -1
- data/bin/dtas-cueedit +1 -1
- data/bin/dtas-enq +1 -1
- data/bin/dtas-mlib +1 -1
- data/bin/dtas-msinkctl +1 -1
- data/bin/dtas-partstats +1 -1
- data/bin/dtas-player +1 -1
- data/bin/dtas-readahead +3 -3
- data/bin/dtas-sinkedit +1 -1
- data/bin/dtas-sourceedit +1 -1
- data/bin/dtas-splitfx +8 -1
- data/bin/dtas-tl +1 -1
- data/bin/dtas-xdelay +1 -1
- data/dtas-linux.gemspec +2 -2
- data/dtas-mpris.gemspec +2 -2
- data/dtas.gemspec +3 -3
- data/dtas.sh +7 -0
- data/examples/zsh-completion/README +3 -0
- data/examples/zsh-completion/_dtas-archive +16 -0
- data/examples/zsh-completion/_dtas-ctl +114 -0
- data/examples/zsh-completion/_dtas-cueedit +7 -0
- data/examples/zsh-completion/_dtas-enq +7 -0
- data/examples/zsh-completion/_dtas-mlib +29 -0
- data/examples/zsh-completion/_dtas-msinkctl +8 -0
- data/examples/zsh-completion/_dtas-partstats +7 -0
- data/examples/zsh-completion/_dtas-sinkedit +11 -0
- data/examples/zsh-completion/_dtas-sourceedit +11 -0
- data/examples/zsh-completion/_dtas-splitfx +17 -0
- data/examples/zsh-completion/_dtas-tl +52 -0
- data/examples/zsh-completion/_dtas-xdelay +17 -0
- data/lib/dtas/buffer/fiddle_splice.rb +216 -0
- data/lib/dtas/buffer/read_write.rb +3 -3
- data/lib/dtas/buffer/splice.rb +9 -5
- data/lib/dtas/buffer.rb +10 -7
- data/lib/dtas/command.rb +1 -1
- data/lib/dtas/compat_onenine.rb +1 -1
- data/lib/dtas/cue_index.rb +1 -1
- data/lib/dtas/disclaimer.rb +1 -1
- data/lib/dtas/edit_client.rb +1 -1
- data/lib/dtas/encoding.rb +8 -9
- data/lib/dtas/fadefx.rb +1 -1
- data/lib/dtas/format.rb +1 -1
- data/lib/dtas/mcache.rb +1 -1
- data/lib/dtas/mlib/migrations/0001_initial.rb +1 -1
- data/lib/dtas/mlib.rb +19 -7
- data/lib/dtas/nonblock.rb +1 -1
- data/lib/dtas/parse_freq.rb +1 -1
- data/lib/dtas/parse_time.rb +1 -1
- data/lib/dtas/partstats.rb +2 -3
- data/lib/dtas/pipe.rb +13 -9
- data/lib/dtas/pipeline.rb +1 -1
- data/lib/dtas/player/client_handler.rb +23 -15
- data/lib/dtas/player.rb +3 -3
- data/lib/dtas/process.rb +1 -1
- data/lib/dtas/replaygain.rb +1 -1
- data/lib/dtas/rg_state.rb +1 -1
- data/lib/dtas/serialize.rb +1 -1
- data/lib/dtas/sigevent/efd.rb +3 -1
- data/lib/dtas/sigevent/fiddle_efd.rb +38 -0
- data/lib/dtas/sigevent/pipe.rb +2 -2
- data/lib/dtas/sigevent.rb +6 -3
- data/lib/dtas/sink.rb +1 -1
- data/lib/dtas/source/av.rb +1 -1
- data/lib/dtas/source/av_ff_common.rb +2 -2
- data/lib/dtas/source/cmd.rb +1 -1
- data/lib/dtas/source/common.rb +1 -1
- data/lib/dtas/source/ff.rb +1 -1
- data/lib/dtas/source/file.rb +1 -1
- data/lib/dtas/source/mp3gain.rb +1 -1
- data/lib/dtas/source/sox.rb +2 -2
- data/lib/dtas/source/splitfx.rb +1 -1
- data/lib/dtas/source.rb +1 -1
- data/lib/dtas/spawn_fix.rb +1 -1
- data/lib/dtas/splitfx.rb +9 -8
- data/lib/dtas/state_file.rb +1 -1
- data/lib/dtas/tfx.rb +1 -1
- data/lib/dtas/track.rb +1 -1
- data/lib/dtas/tracklist.rb +1 -1
- data/lib/dtas/unix_accepted.rb +1 -1
- data/lib/dtas/unix_client.rb +1 -1
- data/lib/dtas/unix_server.rb +1 -1
- data/lib/dtas/util.rb +1 -1
- data/lib/dtas/version.rb +1 -1
- data/lib/dtas/watchable/fiddle_ino.rb +78 -0
- data/lib/dtas/watchable/inotify.rb +13 -0
- data/lib/dtas/watchable.rb +59 -58
- data/lib/dtas/writable_iter.rb +1 -1
- data/lib/dtas/xs.rb +1 -1
- data/lib/dtas.rb +10 -2
- data/man/dtas-archive.1 +15 -15
- data/man/dtas-console.1 +19 -19
- data/man/dtas-ctl.1 +16 -16
- data/man/dtas-cueedit.1 +12 -12
- data/man/dtas-enq.1 +12 -12
- data/man/dtas-env.7 +15 -15
- data/man/dtas-msinkctl.1 +12 -12
- data/man/dtas-player.1 +24 -24
- data/man/dtas-player_effects.7 +9 -9
- data/man/dtas-player_protocol.7 +48 -48
- data/man/dtas-player_sink_examples.7 +15 -15
- data/man/dtas-sinkedit.1 +16 -16
- data/man/dtas-sourceedit.1 +17 -17
- data/man/dtas-splitfx.1 +43 -38
- data/man/dtas-tl.1 +16 -16
- data/man/dtas-xdelay.1 +16 -16
- data/perl/dtas-graph +7 -2
- data/setup.rb +1 -2
- data/test/covshow.rb +1 -1
- data/test/helper.rb +1 -1
- data/test/player_integration.rb +1 -1
- data/test/test_buffer.rb +6 -6
- data/test/test_encoding.rb +1 -1
- data/test/test_env.rb +1 -1
- data/test/test_fadefx.rb +1 -1
- data/test/test_format.rb +1 -1
- data/test/test_format_change.rb +1 -1
- data/test/test_mcache.rb +1 -1
- data/test/test_mlib.rb +1 -1
- data/test/test_parse_freq.rb +1 -1
- data/test/test_pipeline.rb +1 -1
- data/test/test_player.rb +1 -1
- data/test/test_player_client_handler.rb +1 -1
- data/test/test_player_integration.rb +1 -1
- data/test/test_process.rb +1 -1
- data/test/test_rg_integration.rb +1 -1
- data/test/test_rg_state.rb +1 -1
- data/test/test_sigevent.rb +20 -0
- data/test/test_sink.rb +1 -1
- data/test/test_sink_pipe_size.rb +13 -16
- data/test/test_sink_tee_integration.rb +1 -1
- data/test/test_source_av.rb +1 -1
- data/test/test_source_sox.rb +1 -1
- data/test/test_splitfx.rb +1 -1
- data/test/test_tfx.rb +1 -1
- data/test/test_tracklist.rb +1 -1
- data/test/test_unixserver.rb +1 -1
- data/test/test_util.rb +1 -1
- metadata +23 -4
data/INSTALL
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
Uncommon for audio software, dtas is implemented in Ruby.
|
1
|
+
Uncommon for audio software, dtas is currently implemented in Ruby.
|
2
2
|
|
3
3
|
The latest stable release or development snapshot of Ruby is recommended.
|
4
4
|
However, Ruby 1.9.3 and later works, but older versions of Ruby do not.
|
@@ -8,26 +8,16 @@ dtas-player uses SoX by default and you will need it unless you've
|
|
8
8
|
reconfigured dtas-player to use something else.
|
9
9
|
|
10
10
|
mp3gain is required if you want to use ReplayGain with MP3s
|
11
|
+
(it is no longer in new versions of Debian)
|
11
12
|
|
12
13
|
If you only intend to use dtas-cueedit, you will need metaflac(1) from
|
13
14
|
the FLAC package.
|
14
15
|
|
15
|
-
Debian
|
16
|
+
Debian 10+ users can install dependencies easily:
|
16
17
|
|
17
|
-
sudo apt-get install sox libsox-fmt-all
|
18
|
+
sudo apt-get install sox libsox-fmt-all flac ruby-dev ruby-charlock-holmes
|
18
19
|
|
19
|
-
|
20
|
-
|
21
|
-
Be sure to have Ruby development headers and a working C compiler.
|
22
|
-
This will pull in the sleepy_penguin RubyGems for minor
|
23
|
-
speedups. If you cannot be bothered to have a development
|
24
|
-
environment, just use "gem install dtas".
|
25
|
-
|
26
|
-
sudo gem install dtas-linux
|
27
|
-
|
28
|
-
This should pull in the "sleepy_penguin" RubyGems
|
29
|
-
|
30
|
-
For future upgrades of dtas (upgrades to dtas-linux will be infrequent)
|
20
|
+
For future upgrades of dtas
|
31
21
|
|
32
22
|
sudo gem update dtas
|
33
23
|
|
@@ -39,25 +29,21 @@ For future upgrades of dtas (upgrades to dtas-linux will be infrequent)
|
|
39
29
|
|
40
30
|
Grab the latest tarball from our HTTPS site:
|
41
31
|
|
42
|
-
https://80x24.org/dtas/
|
32
|
+
https://80x24.org/dtas/2021/dtas-0.19.0.tar.gz
|
43
33
|
|
44
|
-
$ tar zxvf dtas-0.
|
45
|
-
$ cd dtas-0.
|
34
|
+
$ tar zxvf dtas-0.19.0.tar.gz
|
35
|
+
$ cd dtas-0.19.0
|
46
36
|
$ sudo ruby setup.rb
|
47
37
|
|
48
|
-
GNU/Linux users may optionally install the "sleepy_penguin" package:
|
49
|
-
|
50
|
-
* sleepy_penguin - https://bogomips.org/sleepy_penguin/
|
51
|
-
|
52
38
|
# CONTACT
|
53
39
|
|
54
40
|
Please do not hesitate to send plain-text mail to <dtas-all@nongnu.org>
|
55
41
|
regarding installation and to share your notes/experiences.
|
56
42
|
Mailing list archives available at <https://80x24.org/dtas-all/> or
|
57
|
-
<
|
43
|
+
<https://lists.gnu.org/archive/html/dtas-all/>
|
58
44
|
No subscription is necessary to post to the mailing list.
|
59
45
|
|
60
46
|
# COPYRIGHT
|
61
47
|
|
62
|
-
Copyright 2013-
|
48
|
+
Copyright 2013-2021 all contributors <dtas-all@nongnu.org>
|
63
49
|
License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
data/NEWS
CHANGED
@@ -1,3 +1,106 @@
|
|
1
|
+
# 0.19.0 / 2021-09-05
|
2
|
+
|
3
|
+
dtas 0.19.0 - odd pathname fixes
|
4
|
+
|
5
|
+
|
6
|
+
Non-UTF-8-encoded pathnames now handled properly by dtas-mlib.
|
7
|
+
Shell-unfriendly filenames are handled properly if they require
|
8
|
+
ffmpeg (they were always handled properly when using sox).
|
9
|
+
|
10
|
+
Some minor URL and doc updates, too, and there's a new
|
11
|
+
"make symlink-install" target for users who lack permissions
|
12
|
+
to install RubyGems.
|
13
|
+
|
14
|
+
6 changes since v0.18.1 (2021-02-13):
|
15
|
+
|
16
|
+
mlib: pathnames may be blobs
|
17
|
+
README: replace NNTP URL with NNTPS
|
18
|
+
gemspec: allow building gem without setting VERSION
|
19
|
+
build: add "symlink-install" target
|
20
|
+
do not shell-quote filenames for environment
|
21
|
+
doc: use Tor v3 .onion URLs
|
22
|
+
|
23
|
+
# 0.18.1 / 2021-02-13
|
24
|
+
|
25
|
+
dtas 0.18.1
|
26
|
+
|
27
|
+
|
28
|
+
Mainly seek improvements to dtas-player. The fallback to use
|
29
|
+
charlock-holmes for strangely-encoded files is fixed.
|
30
|
+
|
31
|
+
7 changes since 0.18.0 (2020-02-03):
|
32
|
+
|
33
|
+
splitfx: reduce syscalls for writing comments file
|
34
|
+
splitfx: support --err-suffix option
|
35
|
+
player: fix +/- directional seeks while paused
|
36
|
+
README: update and add more URLs for archives
|
37
|
+
encoding: use CharlockHolmes properly on first run
|
38
|
+
dtas-console: gracefully handle seek failures
|
39
|
+
INSTALL: update dependencies for current Debian stable
|
40
|
+
|
41
|
+
# 0.18.0 / 2020-02-03
|
42
|
+
|
43
|
+
dtas 0.18.0
|
44
|
+
|
45
|
+
|
46
|
+
fiddle is now supported for Linux users without a C compiler or
|
47
|
+
Ruby headers installed to take advantage of inotify(7)
|
48
|
+
functionality and efficiency improvements with splice(2) and
|
49
|
+
eventfd(7).
|
50
|
+
|
51
|
+
For non-RubyGems users, there's some setup.rb fixes thanks
|
52
|
+
to James Rowe.
|
53
|
+
|
54
|
+
Eric Wong (8):
|
55
|
+
doc: fixup leftover ftp://lists.gnu.org links
|
56
|
+
pipe: avoid loading sleepy_penguin
|
57
|
+
provide fiddle-based eventfd implementation
|
58
|
+
buffer: replace sleepy_penguin with fiddle
|
59
|
+
watchable: use fiddle for inotify support
|
60
|
+
doc: remove most recommendations for sleepy_penguin
|
61
|
+
INSTALL: s/bogomips.org/yhbt.net/
|
62
|
+
doc: update copyrights for 2020
|
63
|
+
|
64
|
+
James Rowe (2):
|
65
|
+
setup: update to use RbConfig
|
66
|
+
setup: fix duplicate variable warning
|
67
|
+
|
68
|
+
# 0.17.0 / 2019-11-14
|
69
|
+
|
70
|
+
dtas 0.17.0
|
71
|
+
|
72
|
+
|
73
|
+
dtas-player automatically pauses on sink death (e.g. when an
|
74
|
+
external DAC is unplugged), thanks to Rene Maurer for the
|
75
|
+
feature suggestion.
|
76
|
+
|
77
|
+
zsh completions are also bundled in the examples/ directory
|
78
|
+
thanks to James Rowe.
|
79
|
+
|
80
|
+
There's also a couple of minor bugfixes and documentation
|
81
|
+
updates.
|
82
|
+
|
83
|
+
There's also kwarg warning fixes for Ruby 2.7.0dev. Future
|
84
|
+
components will probably use a more stable glue language
|
85
|
+
than Ruby, and we already have dtas-graph which is Perl5.
|
86
|
+
|
87
|
+
Eric Wong (11):
|
88
|
+
doc: remove inaccurate comment about "GNU-ism"
|
89
|
+
doc: update homepage to point to cgit /about/
|
90
|
+
dtas-graph: show inode number in hex, too
|
91
|
+
dtas-graph: add a short blurb about what it does
|
92
|
+
dtas-console: remove unused variables
|
93
|
+
dtas-console: pass kwargs as-is to String#encode
|
94
|
+
buffer/splice: pass kwargs as-is to tee/splice
|
95
|
+
player: automatically pause if last sink dies
|
96
|
+
readahead: avoid Array#compact and Array#max on `false'
|
97
|
+
doc: use new HTTPS address at lists.gnu.org
|
98
|
+
TODO: add a note about using a more stable glue language
|
99
|
+
|
100
|
+
James Rowe (2):
|
101
|
+
doc: trivial typo fixes
|
102
|
+
Add zsh completion support
|
103
|
+
|
1
104
|
# 0.16.1 / 2019-01-02
|
2
105
|
|
3
106
|
dtas 0.16.1
|
data/README
CHANGED
@@ -25,7 +25,7 @@ for audio. dtas-player supports:
|
|
25
25
|
* ReplayGain (including fallback gain and peak normalization)
|
26
26
|
|
27
27
|
dtas-player is a *nix pipeline and process manager. It may be used
|
28
|
-
spawn and pipe to
|
28
|
+
spawn and pipe to arbitrary Unix commands, not just audio-related
|
29
29
|
commands. It can interactively restart/replace the source (audio
|
30
30
|
decoder) component of a pipeline while keeping the sink (playback
|
31
31
|
endpoint) running.
|
@@ -74,19 +74,25 @@ All feedback (comments, results, feature requests, bug reports, patches,
|
|
74
74
|
pull-requests) via plain-text mail to the mailing list is very much
|
75
75
|
appreciated.
|
76
76
|
|
77
|
-
Please send plain-text mail to the list at <dtas-all@nongnu.org
|
78
|
-
HTML mail will not be read. dtas is for GUI-phobes, by GUI-phobes
|
79
|
-
Mailing list archives available at <
|
80
|
-
|
77
|
+
Please send plain-text mail to the list at <dtas-all@nongnu.org>
|
78
|
+
HTML mail will not be read. dtas is for GUI-phobes, by GUI-phobes.
|
79
|
+
Mailing list archives available at <https://80x24.org/dtas-all/> or
|
80
|
+
<https://lists.gnu.org/archive/html/dtas-all/>.
|
81
|
+
|
81
82
|
No subscription is necessary to post to the mailing list.
|
82
83
|
You may also read via:
|
83
|
-
NNTP: <
|
84
|
-
<nntp://
|
84
|
+
NNTP: <nntps://news.public-inbox.org/inbox.comp.audio.dtas>
|
85
|
+
<nntp://7fh6tueqddpjyxjmgtdiueylzoqt6pt7hec3pukyptlmohoowvhde4yd.onion/inbox.comp.audio.dtas>
|
86
|
+
<nntp://news.gmane.io/gmane.comp.audio.dtas.general>
|
87
|
+
IMAP: <imaps://anon:mous@public-inbox.org/inbox.comp.audio.dtas.0>
|
88
|
+
<imap://anon:mous@7fh6tueqddpjyxjmgtdiueylzoqt6pt7hec3pukyptlmohoowvhde4yd.onion/inbox.comp.audio.dtas.0>
|
85
89
|
Atom: <https://80x24.org/dtas-all/new.atom>
|
90
|
+
<http://7fh6tueqddpjyxjmgtdiueylzoqt6pt7hec3pukyptlmohoowvhde4yd.onion/dtas-all/new.atom>
|
91
|
+
(.onion URLs require Tor: <https://www.torproject.org/>)
|
86
92
|
|
87
93
|
## Copyright
|
88
94
|
|
89
|
-
Copyright 2013-
|
95
|
+
Copyright 2013-2021 all contributors <dtas-all@nongnu.org>
|
90
96
|
License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
91
97
|
|
92
98
|
dtas is copyrighted Free Software by all contributors, see logs
|
data/Rakefile
CHANGED
data/TODO
CHANGED
@@ -3,7 +3,9 @@
|
|
3
3
|
|
4
4
|
* tests for bin/*
|
5
5
|
|
6
|
+
* consider rewriting piecemeal in a more stable glue language than Ruby
|
7
|
+
|
6
8
|
# COPYRIGHT
|
7
9
|
|
8
|
-
Copyright 2013-
|
10
|
+
Copyright 2013-2020 all contributors <dtas-all@nongnu.org>
|
9
11
|
License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
data/bin/dtas-archive
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2015-
|
2
|
+
# Copyright (C) 2015-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
usage = "#$0 SOURCE DESTINATION"
|
data/bin/dtas-console
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2013-
|
2
|
+
# Copyright (C) 2013-2021 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
#
|
@@ -53,8 +53,6 @@ tfmt = update_tfmt(prec_step[prec_nr], tsec)
|
|
53
53
|
events = []
|
54
54
|
interval = 1.0 / 10 ** prec_nr
|
55
55
|
|
56
|
-
pause = nil
|
57
|
-
|
58
56
|
def show_events(lineno, screen, events)
|
59
57
|
Curses.setpos(lineno += 1, 0)
|
60
58
|
Curses.clrtoeol
|
@@ -114,14 +112,14 @@ def rg_string(rg, current)
|
|
114
112
|
rv
|
115
113
|
end
|
116
114
|
|
117
|
-
def may_fail(
|
115
|
+
def may_fail(c, req, events)
|
116
|
+
res = c.req(req)
|
118
117
|
events << res if res != "OK"
|
119
118
|
end
|
120
119
|
|
121
120
|
pre_mute_vol = 1.0
|
122
121
|
enc_locale = Encoding.find("locale")
|
123
122
|
$stdout.set_encoding(enc_locale)
|
124
|
-
enc_opts = { undef: :replace, invalid: :replace, replace: '?' }
|
125
123
|
begin
|
126
124
|
Curses.init_screen
|
127
125
|
Curses.nonl
|
@@ -135,7 +133,6 @@ begin
|
|
135
133
|
pfmt = cur['format']
|
136
134
|
elapsed = samples = 0
|
137
135
|
fmt = total = ''
|
138
|
-
paused = false
|
139
136
|
if current = cur['current']
|
140
137
|
infile = current['infile'] || current['command']
|
141
138
|
elapsed = DTAS.now - current['spawn_at']
|
@@ -150,7 +147,6 @@ begin
|
|
150
147
|
end
|
151
148
|
elsif cur['paused'] && infile = cur['current_paused']
|
152
149
|
fmt = "[paused] (#{fmt_to_s(pfmt)})"
|
153
|
-
paused = true
|
154
150
|
infile = infile['command'] if Hash === infile
|
155
151
|
if Array === infile
|
156
152
|
infile, elapsed = infile
|
@@ -169,7 +165,8 @@ begin
|
|
169
165
|
# FS encoding != locale encoding, but we need to display an FS path
|
170
166
|
# name to whatever locale the terminal is encoded to, so force it
|
171
167
|
# and risk mojibake...
|
172
|
-
infile.encode(enc_locale,
|
168
|
+
infile.encode(enc_locale,
|
169
|
+
undef: :replace, invalid: :replace, replace: '?')
|
173
170
|
Curses.setpos(lineno += 1, 0)
|
174
171
|
Curses.clrtoeol
|
175
172
|
Curses.addstr(infile)
|
@@ -220,10 +217,9 @@ begin
|
|
220
217
|
case event
|
221
218
|
when "pause"
|
222
219
|
if current
|
223
|
-
|
220
|
+
current['infile'] || current['command']
|
224
221
|
end
|
225
222
|
when %r{\Afile }
|
226
|
-
pause = nil
|
227
223
|
end
|
228
224
|
events << "#{Time.now.strftime(tfmt)} #{event}"
|
229
225
|
# something happened, refresh current
|
@@ -232,17 +228,17 @@ begin
|
|
232
228
|
when $stdin
|
233
229
|
# keybindings taken from mplayer / vi
|
234
230
|
case key = Curses.getch
|
235
|
-
when "j" then c
|
236
|
-
when "k" then c
|
231
|
+
when "j" then may_fail(c, "seek -5", events)
|
232
|
+
when "k" then may_fail(c, "seek +5", events)
|
237
233
|
when "q" then exit(0)
|
238
|
-
when Curses::KEY_DOWN then c
|
239
|
-
when Curses::KEY_UP then c
|
240
|
-
when Curses::KEY_LEFT then c
|
241
|
-
when Curses::KEY_RIGHT then c
|
242
|
-
when Curses::KEY_BACKSPACE then c
|
234
|
+
when Curses::KEY_DOWN then may_fail(c, "seek -60", events)
|
235
|
+
when Curses::KEY_UP then may_fail(c, "seek +60", events)
|
236
|
+
when Curses::KEY_LEFT then may_fail(c, "seek -10", events)
|
237
|
+
when Curses::KEY_RIGHT then may_fail(c, "seek +10", events)
|
238
|
+
when Curses::KEY_BACKSPACE then may_fail(c, "seek 0", events)
|
243
239
|
# yes, some of us have long audio files
|
244
|
-
when Curses::KEY_PPAGE then c
|
245
|
-
when Curses::KEY_NPAGE then c
|
240
|
+
when Curses::KEY_PPAGE then may_fail(c, "seek +600", events)
|
241
|
+
when Curses::KEY_NPAGE then may_fail(c, "seek -600", events)
|
246
242
|
when '9' then c.req_ok('rg volume-=0.01')
|
247
243
|
when '0' then c.req_ok('rg volume+=0.01')
|
248
244
|
when '=' then c.req_ok('rg volume=1')
|
@@ -253,8 +249,8 @@ begin
|
|
253
249
|
when "f" then c.req_ok("rg fallback_gain-=1")
|
254
250
|
when ">" then c.req_ok("tl next")
|
255
251
|
when "<" then c.req_ok("tl prev")
|
256
|
-
when "!" then may_fail(c
|
257
|
-
when "@" then may_fail(c
|
252
|
+
when "!" then may_fail(c, "cue prev", events)
|
253
|
+
when "@" then may_fail(c, "cue next", events)
|
258
254
|
when "o" then tfmt = update_tfmt(prec_step[prec_nr], tsec = !tsec)
|
259
255
|
when " "
|
260
256
|
c.req("play_pause")
|
data/bin/dtas-ctl
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2013-
|
2
|
+
# Copyright (C) 2013-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
require 'dtas/unix_client'
|
data/bin/dtas-cueedit
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2013-
|
2
|
+
# Copyright (C) 2013-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
require 'tempfile'
|
data/bin/dtas-enq
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2013-
|
2
|
+
# Copyright (C) 2013-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
require 'dtas/unix_client'
|
data/bin/dtas-mlib
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2015-
|
2
|
+
# Copyright (C) 2015-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
usage = "#$0 [-d DATABASE-URI] ACTION [ARGS]"
|
data/bin/dtas-msinkctl
CHANGED
data/bin/dtas-partstats
CHANGED
data/bin/dtas-player
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2013-
|
2
|
+
# Copyright (C) 2013-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
Thread.abort_on_exception = $stderr.sync = $stdout.sync = true
|
data/bin/dtas-readahead
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2015-
|
2
|
+
# Copyright (C) 2015-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
#
|
@@ -57,7 +57,7 @@ def seek_to_cur_pos(cur_pid, fp)
|
|
57
57
|
end
|
58
58
|
end
|
59
59
|
rescue Errno::ENOENT => e # race, process is dead
|
60
|
-
return
|
60
|
+
return nil
|
61
61
|
rescue => e
|
62
62
|
warn "error reading FDs from for PID:#{cur_pid}: #{e.message}"
|
63
63
|
end
|
@@ -71,7 +71,7 @@ def seek_to_cur_pos(cur_pid, fp)
|
|
71
71
|
end
|
72
72
|
pos
|
73
73
|
rescue Errno::ENOENT => e # race, process is dead
|
74
|
-
return
|
74
|
+
return nil
|
75
75
|
end
|
76
76
|
|
77
77
|
def children_of(ppid)
|
data/bin/dtas-sinkedit
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2013-
|
2
|
+
# Copyright (C) 2013-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
require 'optparse'
|
data/bin/dtas-sourceedit
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
|
-
# Copyright (C) 2013-
|
2
|
+
# Copyright (C) 2013-2020 all contributors <dtas-all@nongnu.org>
|
3
3
|
# License: GPL-3.0+ <https://www.gnu.org/licenses/gpl-3.0.txt>
|
4
4
|
# frozen_string_literal: true
|
5
5
|
require 'optparse'
|