fastlane-plugin-appicon 0.2.0 → 0.3.0
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/README.md +15 -2
- data/lib/fastlane/plugin/appicon/actions/appicon_action.rb +6 -5
- data/lib/fastlane/plugin/appicon/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 24a0792a488d2de605deff1c9696637c1e21485d
|
4
|
+
data.tar.gz: 2e6204b9efd7a591948a4e52a887f3e29059b8db
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3bedaf6d41c10498e9a920b6241a71ea2f446b8e832e741392789daa367b4369fcea3268773b2468099bb78c32fb91f75e8292725345ec840f917fb8d9885096
|
7
|
+
data.tar.gz: 7c32da3f5e58402eff4d543e1f7045a5b2c491addc95a8d884772a840133cfdda0b8d1021b758c45a0adcf467397949732bdae048ddafb4964d300092be13f7f
|
data/README.md
CHANGED
@@ -2,6 +2,8 @@
|
|
2
2
|
|
3
3
|
[](https://rubygems.org/gems/fastlane-plugin-appicon)
|
4
4
|
|
5
|
+

|
6
|
+
|
5
7
|
## Getting Started
|
6
8
|
|
7
9
|
This project is a [fastlane](https://github.com/fastlane/fastlane) plugin. To get started with `fastlane-plugin-appicon`, add it to your project by running:
|
@@ -12,11 +14,22 @@ fastlane add_plugin appicon
|
|
12
14
|
|
13
15
|
## About appicon
|
14
16
|
|
15
|
-
Generate required icon sizes and iconset from a master application icon.
|
17
|
+
Generate required icon sizes and iconset from a master application icon.
|
18
|
+
|
19
|
+
Since many apps use a single 1024x1024 icon to produce all the required sizes from, why not automate the process and save lots of time?
|
16
20
|
|
17
21
|
## Example
|
18
22
|
|
19
|
-
Check out the [example `Fastfile`](fastlane/Fastfile) to see how to use this plugin. Try it by cloning the repo, running `fastlane install_plugins` and `bundle exec fastlane test`.
|
23
|
+
Check out the [example `Fastfile`](fastlane/Fastfile) to see how to use this plugin. Try it by cloning the repo, running `fastlane install_plugins` and `bundle exec fastlane test`.
|
24
|
+
|
25
|
+
Just specify the source image using the `appicon_image_file`. Optionally specify the devices using `appicon_devices` and the destination path using `appicon_path`.
|
26
|
+
|
27
|
+
```ruby
|
28
|
+
lane :test do
|
29
|
+
appicon(appicon_image_file: 'spec/fixtures/Themoji.png',
|
30
|
+
appicon_devices: [:ipad, :iphone])
|
31
|
+
end
|
32
|
+
```
|
20
33
|
|
21
34
|
## Run tests for this plugin
|
22
35
|
|
@@ -22,9 +22,9 @@ module Fastlane
|
|
22
22
|
require 'mini_magick'
|
23
23
|
image = MiniMagick::Image.open(fname)
|
24
24
|
|
25
|
-
UI.user_error!
|
26
|
-
UI.user_error!
|
27
|
-
UI.user_error!
|
25
|
+
UI.user_error!("Minimum width of input image should be 1024") if image.width < 1024
|
26
|
+
UI.user_error!("Minimum height of input image should be 1024") if image.height < 1024
|
27
|
+
UI.user_error!("Input image should be square") if image.width != image.height
|
28
28
|
|
29
29
|
FileUtils.mkdir_p(basepath)
|
30
30
|
|
@@ -55,12 +55,13 @@ module Fastlane
|
|
55
55
|
'images' => images,
|
56
56
|
'info' => {
|
57
57
|
'version' => 1,
|
58
|
-
'author' => 'fastlane'
|
58
|
+
'author' => 'fastlane'
|
59
59
|
}
|
60
60
|
}
|
61
61
|
|
62
62
|
require 'json'
|
63
|
-
File.write(basepath
|
63
|
+
File.write(File.join(basepath, 'Contents.json'), JSON.dump(contents))
|
64
|
+
UI.success("Successfully stored app icon at '#{basepath}'")
|
64
65
|
end
|
65
66
|
|
66
67
|
def self.description
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fastlane-plugin-appicon
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Boris Bügling
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-07-
|
11
|
+
date: 2016-07-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: mini_magick
|