capa 0.1.2 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/capa/gif_generator.rb +15 -3
- data/lib/capa/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: 8affe03cde23f2e7e12496e02b06ad01973b816c85b5091d7f2d9865654d45a0
|
|
4
|
+
data.tar.gz: 920a1d1fe3b8304a1facd0ff88a2d0e3a8d017cf57ec406e7d2134aeeba1fedc
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b1b028eafeccb02cc99a1fec78808fd9af550e26574064d31cab6421fa3fc4cfa078edaa0f7fa91eed041f9a65edef29e189a34f030cdc28a6a8d4ae0885010a
|
|
7
|
+
data.tar.gz: fd738c7e35deaf48f842426e26cc6148ef93b93894dca2575365e4aeab8f4fd1bc4b89e6dfdf8ef3a00ff1ab571a04d4bceec2fd087359835e09e9408f497503
|
data/lib/capa/gif_generator.rb
CHANGED
|
@@ -12,8 +12,20 @@ class GIFGenerator
|
|
|
12
12
|
abort("File not found: #{@input_video}") unless File.exists?(@input_video)
|
|
13
13
|
puts "Generating GIF, please wait..."
|
|
14
14
|
`gifify #{@input_video} -o #{@output_gif} --resize 300:-1 --colors 220 --fps 7`
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
output_directory = Dir.pwd
|
|
16
|
+
video_path = "#{output_directory}/#{@input_video}"
|
|
17
|
+
gif_path = "#{output_directory}/#{@output_gif}"
|
|
18
|
+
|
|
19
|
+
if File.exists?(video_path)
|
|
20
|
+
puts "Video: #{video_path}"
|
|
21
|
+
else
|
|
22
|
+
puts "Error generating video"
|
|
23
|
+
end
|
|
24
|
+
|
|
25
|
+
if File.exists?(gif_path)
|
|
26
|
+
puts "GIF: #{gif_path}"
|
|
27
|
+
else
|
|
28
|
+
puts "Error generating GIF"
|
|
29
|
+
end
|
|
18
30
|
end
|
|
19
31
|
end
|
data/lib/capa/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: capa
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.1.
|
|
4
|
+
version: 0.1.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Alex Salom
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2018-10-
|
|
11
|
+
date: 2018-10-18 00:00:00.000000000 Z
|
|
12
12
|
dependencies: []
|
|
13
13
|
description: capa can record animated GIFs (and videos) from the iOS Simulator and
|
|
14
14
|
the Android Emulator because a GIF is worth a thousand lines of code.
|