mm_tool 0.1.6 → 0.1.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mm_tool/application_main.rb +6 -4
- data/lib/mm_tool/mm_movie.rb +1 -1
- data/lib/mm_tool/mm_movie_stream.rb +1 -1
- data/lib/mm_tool/mm_tool_cli.rb +18 -8
- data/lib/mm_tool/user_defaults.rb +13 -0
- data/lib/mm_tool/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 58f5ac411fa199ac4b62febe8ca5896dfa7b490b4114038d8272681cee38b6d7
|
4
|
+
data.tar.gz: bd6f59ce638b8e374ecc63213570a45ae84d7341e1796e3588887ca1ff948de1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7d32af155244f7019de5b7c9e9e37a89d91cc805463708f7f295efb7ac79b7982673d9d4e39bc18ef98aec00592642e8e1f9ec8e9588a51dd0df6f7bc53e2cbb
|
7
|
+
data.tar.gz: db86d0614d20fc56ccf75542966535543cd46a33a90015bfd0644293659a2c77135013bbf44448a0108ef3ffd7f36d85451f4d24454f807893fb2b1ea7eae2a3
|
@@ -111,10 +111,12 @@ module MmTool
|
|
111
111
|
output(file_name)
|
112
112
|
output(movie.format_table)
|
113
113
|
output(movie.stream_table)
|
114
|
-
|
115
|
-
|
116
|
-
|
117
|
-
|
114
|
+
if @defaults[:shell_commands]
|
115
|
+
output("echo \"#{File.basename(file_name)}\" ; \\", true)
|
116
|
+
output("#{movie.command_rename} ; \\", true)
|
117
|
+
output("#{movie.command_transcode} ; \\", true)
|
118
|
+
output(movie.command_review_post, true)
|
119
|
+
end
|
118
120
|
output("\n\n", true)
|
119
121
|
end
|
120
122
|
end # if
|
data/lib/mm_tool/mm_movie.rb
CHANGED
@@ -148,7 +148,7 @@ module MmTool
|
|
148
148
|
# running the transcode command
|
149
149
|
#------------------------------------------------------------
|
150
150
|
def command_review_post
|
151
|
-
"\"#{$0}\" --no-use-external-subs \"#{output_path}\""
|
151
|
+
"\"#{$0}\" -is --no-use-external-subs \"#{output_path}\""
|
152
152
|
end
|
153
153
|
|
154
154
|
|
@@ -465,7 +465,7 @@ module MmTool
|
|
465
465
|
def encoder_string(for_codec:)
|
466
466
|
case for_codec.downcase
|
467
467
|
when 'hevc'
|
468
|
-
"libx265 -crf 28 -x265-params log-level=error"
|
468
|
+
"libx265 -crf 28 -x265-params log-level=error -force_key_frames chapters"
|
469
469
|
when 'h264'
|
470
470
|
"libx264 -crf 23"
|
471
471
|
when 'aac'
|
data/lib/mm_tool/mm_tool_cli.rb
CHANGED
@@ -106,23 +106,27 @@ module MmTool
|
|
106
106
|
case char
|
107
107
|
|
108
108
|
when 'h'
|
109
|
-
args.insert(1,
|
109
|
+
args.insert(1, '--help')
|
110
110
|
when 'i'
|
111
|
-
args.insert(1,
|
111
|
+
args.insert(1, '--no-info-header')
|
112
112
|
when 'I'
|
113
113
|
args.insert(1, '--info-header')
|
114
|
+
when 's'
|
115
|
+
args.insert(1, '--no-shell-commands')
|
116
|
+
when 'S'
|
117
|
+
args.insert(1, '--shell-commands')
|
114
118
|
when 't'
|
115
|
-
args.insert(1,
|
119
|
+
args.insert(1, '--transcode')
|
116
120
|
when 'T'
|
117
|
-
args.insert(1,
|
121
|
+
args.insert(1, '-no-transcode')
|
118
122
|
when 'u'
|
119
|
-
args.insert(1,
|
123
|
+
args.insert(1, '--no-fix-undefined-language')
|
120
124
|
when 'U'
|
121
|
-
args.insert(1,
|
125
|
+
args.insert(1, '--fix-undefined-language')
|
122
126
|
when 'p'
|
123
|
-
args.insert(1,
|
127
|
+
args.insert(1, '--dump')
|
124
128
|
when 'P'
|
125
|
-
args.insert(1,
|
129
|
+
args.insert(1, '--no-dump')
|
126
130
|
else
|
127
131
|
OutputHelper.print_error_and_exit("Error: option #{C.bold(args[0])} was specified, but I don't know what that means.")
|
128
132
|
end
|
@@ -171,6 +175,12 @@ module MmTool
|
|
171
175
|
when '--info-header'
|
172
176
|
@defaults[:info_header] = true
|
173
177
|
|
178
|
+
when '--no-shell-commands'
|
179
|
+
@defaults[:shell_commands] = false
|
180
|
+
|
181
|
+
when '--shell-commands'
|
182
|
+
@defaults[:shell_commands] = true
|
183
|
+
|
174
184
|
when '--version'
|
175
185
|
puts "#{File.basename $0}, version #{MmTool::VERSION}"
|
176
186
|
exit 0
|
@@ -88,6 +88,19 @@ module MmTool
|
|
88
88
|
HEREDOC
|
89
89
|
},
|
90
90
|
|
91
|
+
:shell_commands => {
|
92
|
+
:default => true,
|
93
|
+
:value => nil,
|
94
|
+
:arg_short => '-s',
|
95
|
+
:arg_long => '--no-shell-commands',
|
96
|
+
:arg_format => nil,
|
97
|
+
:item_label => nil,
|
98
|
+
:help_group => 'Main Options',
|
99
|
+
:help_desc => <<~HEREDOC
|
100
|
+
Don't show the shell commands that should be executed at the end of the output. Good for showing the table only.
|
101
|
+
HEREDOC
|
102
|
+
},
|
103
|
+
|
91
104
|
:version => {
|
92
105
|
:default => false,
|
93
106
|
:value => nil,
|
data/lib/mm_tool/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
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.8
|
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: 2023-08-07 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: tty-table
|