mm_tool 0.1.3 → 0.1.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -0
- data/lib/mm_tool/application_main.rb +3 -4
- data/lib/mm_tool/mm_movie.rb +3 -0
- data/lib/mm_tool/mm_movie_stream.rb +2 -2
- data/lib/mm_tool/version.rb +1 -1
- data/mm_tool.gemspec +25 -11
- metadata +36 -9
- data/Gemfile.lock +0 -132
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 733fa9ad6f8e6612fa1cff346c70c8d59118a3e2c4327020f48cdc18d2855de4
|
4
|
+
data.tar.gz: 6b147c962d92d00aa8b3c7cb17487f16c8c43e2da3d484e763069c7d22c8b97b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2e02a0d14c36b6293f0f83d98aabf8355c87640983d8dcee1b9e20898bb76f2826dcc3a6523f06edf9db9986f67c0a81eee00e410c8234f280a00098e80d9aca
|
7
|
+
data.tar.gz: d09e99c83423ee59fb1fa298aa0235dcfe507ff3fdfb2ee6a12f15b23fc7c7eb5088964cda583a3dc17064eadc42b3e56b82bb85314c247390095bcb0c6f8b76
|
data/README.md
CHANGED
@@ -72,7 +72,7 @@ module MmTool
|
|
72
72
|
info_table_src << ["Disposition Columns:", MmMovie.dispositions.join(', ')]
|
73
73
|
info_table_src << ["Transcode File Location:", self.tempfile ? tempfile&.path : 'n/a']
|
74
74
|
|
75
|
-
info_table = C.bold("Looking for file(s) and processing them with the following options:\n")
|
75
|
+
info_table = C.bold("Looking for file(s) and processing them with the following options:\n").dup
|
76
76
|
info_table << info_table_src.render(:basic) do |renderer|
|
77
77
|
a = @defaults.label_value_pairs.map {|p| p[0].length }.max + 1
|
78
78
|
b = OutputHelper.console_width - a - 2
|
@@ -111,6 +111,7 @@ module MmTool
|
|
111
111
|
output(file_name)
|
112
112
|
output(movie.format_table)
|
113
113
|
output(movie.stream_table)
|
114
|
+
output("echo '#{File.basename(file_name)}' ; \\", true)
|
114
115
|
output("#{movie.command_rename} ; \\", true)
|
115
116
|
output("#{movie.command_transcode} ; \\", true)
|
116
117
|
output(movie.command_review_post, true)
|
@@ -147,10 +148,8 @@ module MmTool
|
|
147
148
|
|
148
149
|
extensions = @defaults[:container_files]&.join(',')
|
149
150
|
Dir.chdir(file_or_dir) do
|
150
|
-
# Dir.glob("**/*.{#{extensions}}").map {|path| File.expand_path(path) }.sort.each do |file|
|
151
151
|
Dir.glob("**/*.{#{extensions}}").map {|path| File.expand_path(path) }.sort(&NaturalSort).each do |file|
|
152
|
-
|
153
|
-
# run_loop(file)
|
152
|
+
run_loop(file)
|
154
153
|
end
|
155
154
|
end
|
156
155
|
|
data/lib/mm_tool/mm_movie.rb
CHANGED
@@ -127,6 +127,9 @@ module MmTool
|
|
127
127
|
#------------------------------------------------------------
|
128
128
|
def command_transcode
|
129
129
|
command = ["ffmpeg \\"]
|
130
|
+
command << " -hide_banner \\"
|
131
|
+
command << " -loglevel error \\"
|
132
|
+
command << " -stats \\"
|
130
133
|
@streams.each {|stream| command |= [" #{stream.instruction_input}"] if stream.instruction_input }
|
131
134
|
@streams.each {|stream| command << " #{stream.instruction_map}" if stream.instruction_map }
|
132
135
|
@streams.each {|stream| command << " #{stream.instruction_action}" if stream.instruction_action }
|
@@ -465,9 +465,9 @@ module MmTool
|
|
465
465
|
def encoder_string(for_codec:)
|
466
466
|
case for_codec.downcase
|
467
467
|
when 'hevc'
|
468
|
-
"libx265 -crf 28 -
|
468
|
+
"libx265 -crf 28 -x265-params log-level=error"
|
469
469
|
when 'h264'
|
470
|
-
"libx264 -crf 23
|
470
|
+
"libx264 -crf 23"
|
471
471
|
when 'aac'
|
472
472
|
"libfdk_aac"
|
473
473
|
else
|
data/lib/mm_tool/version.rb
CHANGED
data/mm_tool.gemspec
CHANGED
@@ -3,18 +3,28 @@ lib = File.expand_path("../lib", __FILE__)
|
|
3
3
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
4
|
require "mm_tool/version"
|
5
5
|
|
6
|
+
|
7
|
+
# We should work with any 2.0 version of Ruby, but I'm no longer testing them
|
8
|
+
# for regressions. Version 2.6.0 goes back to December 2018, and is a suitable
|
9
|
+
# minimum version.
|
10
|
+
|
11
|
+
#rb_needed = ['~> 2.0']
|
12
|
+
|
13
|
+
|
6
14
|
Gem::Specification.new do |spec|
|
7
|
-
spec.name = 'mm_tool'
|
8
|
-
spec.version = MmTool::VERSION
|
9
|
-
spec.authors = ['Jim Derry']
|
10
|
-
spec.email = ['balthisar@gmail.com']
|
11
15
|
|
12
|
-
spec.
|
13
|
-
spec.
|
14
|
-
spec.
|
15
|
-
spec.
|
16
|
+
# spec.required_ruby_version = rb_needed
|
17
|
+
spec.name = 'mm_tool'
|
18
|
+
spec.version = MmTool::VERSION
|
19
|
+
spec.authors = ['Jim Derry']
|
20
|
+
spec.email = ['balthisar@gmail.com']
|
21
|
+
|
22
|
+
spec.summary = 'Curate your movie files.'
|
23
|
+
spec.description = 'A tool for curating your movie files.'
|
24
|
+
spec.homepage = 'https://github.com/balthisar/mm_tool'
|
25
|
+
spec.license = 'MIT'
|
16
26
|
|
17
|
-
spec.platform
|
27
|
+
spec.platform = Gem::Platform::RUBY
|
18
28
|
|
19
29
|
|
20
30
|
# Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
|
@@ -39,13 +49,17 @@ Gem::Specification.new do |spec|
|
|
39
49
|
|
40
50
|
|
41
51
|
# Additional dependencies
|
42
|
-
spec.add_runtime_dependency 'tty', "~>0.10"
|
52
|
+
spec.add_runtime_dependency 'tty-table', "~>0.10"
|
53
|
+
spec.add_runtime_dependency 'tty-command', "~>0.10"
|
54
|
+
spec.add_runtime_dependency 'tty-which', "~>0.4"
|
55
|
+
|
43
56
|
spec.add_runtime_dependency 'streamio-ffmpeg'
|
44
57
|
spec.add_runtime_dependency 'bytesize'
|
45
58
|
spec.add_runtime_dependency 'natural_sort', "0.3.0"
|
46
59
|
|
47
60
|
# Development dependencies
|
48
|
-
spec.add_development_dependency "bundler"
|
61
|
+
spec.add_development_dependency "bundler"
|
49
62
|
spec.add_development_dependency "rake"
|
50
63
|
spec.add_development_dependency 'git'
|
64
|
+
|
51
65
|
end
|
metadata
CHANGED
@@ -1,17 +1,17 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mm_tool
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jim Derry
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-08-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name: tty
|
14
|
+
name: tty-table
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
@@ -24,6 +24,34 @@ dependencies:
|
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0.10'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: tty-command
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0.10'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0.10'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: tty-which
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0.4'
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0.4'
|
27
55
|
- !ruby/object:Gem::Dependency
|
28
56
|
name: streamio-ffmpeg
|
29
57
|
requirement: !ruby/object:Gem::Requirement
|
@@ -70,16 +98,16 @@ dependencies:
|
|
70
98
|
name: bundler
|
71
99
|
requirement: !ruby/object:Gem::Requirement
|
72
100
|
requirements:
|
73
|
-
- - "
|
101
|
+
- - ">="
|
74
102
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
103
|
+
version: '0'
|
76
104
|
type: :development
|
77
105
|
prerelease: false
|
78
106
|
version_requirements: !ruby/object:Gem::Requirement
|
79
107
|
requirements:
|
80
|
-
- - "
|
108
|
+
- - ">="
|
81
109
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
110
|
+
version: '0'
|
83
111
|
- !ruby/object:Gem::Dependency
|
84
112
|
name: rake
|
85
113
|
requirement: !ruby/object:Gem::Requirement
|
@@ -119,7 +147,6 @@ files:
|
|
119
147
|
- ".gitattributes"
|
120
148
|
- ".gitignore"
|
121
149
|
- Gemfile
|
122
|
-
- Gemfile.lock
|
123
150
|
- LICENSE.md
|
124
151
|
- README.md
|
125
152
|
- Rakefile
|
@@ -158,7 +185,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
158
185
|
- !ruby/object:Gem::Version
|
159
186
|
version: '0'
|
160
187
|
requirements: []
|
161
|
-
rubygems_version: 3.0.
|
188
|
+
rubygems_version: 3.0.9
|
162
189
|
signing_key:
|
163
190
|
specification_version: 4
|
164
191
|
summary: Curate your movie files.
|
data/Gemfile.lock
DELETED
@@ -1,132 +0,0 @@
|
|
1
|
-
PATH
|
2
|
-
remote: .
|
3
|
-
specs:
|
4
|
-
mm_tool (0.1.3)
|
5
|
-
bytesize
|
6
|
-
natural_sort (= 0.3.0)
|
7
|
-
streamio-ffmpeg
|
8
|
-
tty (~> 0.10)
|
9
|
-
|
10
|
-
GEM
|
11
|
-
remote: https://rubygems.org/
|
12
|
-
specs:
|
13
|
-
bytesize (0.1.0)
|
14
|
-
diff-lcs (1.4.4)
|
15
|
-
equatable (0.6.1)
|
16
|
-
git (1.7.0)
|
17
|
-
rchardet (~> 1.8)
|
18
|
-
kramdown (1.16.2)
|
19
|
-
multi_json (1.15.0)
|
20
|
-
natural_sort (0.3.0)
|
21
|
-
necromancer (0.5.1)
|
22
|
-
pastel (0.7.4)
|
23
|
-
equatable (~> 0.6)
|
24
|
-
tty-color (~> 0.5)
|
25
|
-
rake (13.0.1)
|
26
|
-
rchardet (1.8.0)
|
27
|
-
rouge (3.25.0)
|
28
|
-
streamio-ffmpeg (3.0.2)
|
29
|
-
multi_json (~> 1.8)
|
30
|
-
strings (0.1.8)
|
31
|
-
strings-ansi (~> 0.1)
|
32
|
-
unicode-display_width (~> 1.5)
|
33
|
-
unicode_utils (~> 1.4)
|
34
|
-
strings-ansi (0.1.0)
|
35
|
-
thor (0.20.3)
|
36
|
-
tty (0.10.0)
|
37
|
-
bundler (~> 1.16, < 2.0)
|
38
|
-
equatable (~> 0.5)
|
39
|
-
pastel (~> 0.7.2)
|
40
|
-
thor (~> 0.20.0)
|
41
|
-
tty-box (~> 0.4.1)
|
42
|
-
tty-color (~> 0.5)
|
43
|
-
tty-command (~> 0.9.0)
|
44
|
-
tty-config (~> 0.3.2)
|
45
|
-
tty-cursor (~> 0.7)
|
46
|
-
tty-editor (~> 0.5)
|
47
|
-
tty-file (~> 0.8.0)
|
48
|
-
tty-font (~> 0.4.0)
|
49
|
-
tty-logger (~> 0.2.0)
|
50
|
-
tty-markdown (~> 0.6.0)
|
51
|
-
tty-pager (~> 0.12)
|
52
|
-
tty-pie (~> 0.3.0)
|
53
|
-
tty-platform (~> 0.2)
|
54
|
-
tty-progressbar (~> 0.17)
|
55
|
-
tty-prompt (~> 0.19)
|
56
|
-
tty-screen (~> 0.7)
|
57
|
-
tty-spinner (~> 0.9)
|
58
|
-
tty-table (~> 0.11.0)
|
59
|
-
tty-tree (~> 0.3)
|
60
|
-
tty-which (~> 0.4)
|
61
|
-
tty-box (0.4.1)
|
62
|
-
pastel (~> 0.7.2)
|
63
|
-
strings (~> 0.1.6)
|
64
|
-
tty-cursor (~> 0.7)
|
65
|
-
tty-color (0.6.0)
|
66
|
-
tty-command (0.9.0)
|
67
|
-
pastel (~> 0.7.0)
|
68
|
-
tty-config (0.3.2)
|
69
|
-
tty-cursor (0.7.1)
|
70
|
-
tty-editor (0.5.1)
|
71
|
-
tty-prompt (~> 0.19)
|
72
|
-
tty-which (~> 0.4)
|
73
|
-
tty-file (0.8.0)
|
74
|
-
diff-lcs (~> 1.3)
|
75
|
-
pastel (~> 0.7.2)
|
76
|
-
tty-prompt (~> 0.18)
|
77
|
-
tty-font (0.4.0)
|
78
|
-
tty-logger (0.2.0)
|
79
|
-
pastel (~> 0.7.0)
|
80
|
-
tty-markdown (0.6.0)
|
81
|
-
kramdown (~> 1.16.2)
|
82
|
-
pastel (~> 0.7.2)
|
83
|
-
rouge (~> 3.3)
|
84
|
-
strings (~> 0.1.4)
|
85
|
-
tty-color (~> 0.4)
|
86
|
-
tty-screen (~> 0.6)
|
87
|
-
tty-pager (0.13.0)
|
88
|
-
strings (~> 0.1.8)
|
89
|
-
tty-screen (~> 0.8)
|
90
|
-
tty-pie (0.3.0)
|
91
|
-
pastel (~> 0.7.3)
|
92
|
-
tty-cursor (~> 0.7)
|
93
|
-
tty-platform (0.3.0)
|
94
|
-
tty-progressbar (0.17.0)
|
95
|
-
strings-ansi (~> 0.1.0)
|
96
|
-
tty-cursor (~> 0.7)
|
97
|
-
tty-screen (~> 0.7)
|
98
|
-
unicode-display_width (~> 1.6)
|
99
|
-
tty-prompt (0.21.0)
|
100
|
-
necromancer (~> 0.5.0)
|
101
|
-
pastel (~> 0.7.0)
|
102
|
-
tty-reader (~> 0.7.0)
|
103
|
-
tty-reader (0.7.0)
|
104
|
-
tty-cursor (~> 0.7)
|
105
|
-
tty-screen (~> 0.7)
|
106
|
-
wisper (~> 2.0.0)
|
107
|
-
tty-screen (0.8.1)
|
108
|
-
tty-spinner (0.9.3)
|
109
|
-
tty-cursor (~> 0.7)
|
110
|
-
tty-table (0.11.0)
|
111
|
-
equatable (~> 0.6)
|
112
|
-
necromancer (~> 0.5)
|
113
|
-
pastel (~> 0.7.2)
|
114
|
-
strings (~> 0.1.5)
|
115
|
-
tty-screen (~> 0.7)
|
116
|
-
tty-tree (0.4.0)
|
117
|
-
tty-which (0.4.2)
|
118
|
-
unicode-display_width (1.7.0)
|
119
|
-
unicode_utils (1.4.0)
|
120
|
-
wisper (2.0.1)
|
121
|
-
|
122
|
-
PLATFORMS
|
123
|
-
ruby
|
124
|
-
|
125
|
-
DEPENDENCIES
|
126
|
-
bundler (~> 1.17.3)
|
127
|
-
git
|
128
|
-
mm_tool!
|
129
|
-
rake
|
130
|
-
|
131
|
-
BUNDLED WITH
|
132
|
-
1.17.3
|