Create a gist now

Instantly share code, notes, and snippets.

@fra3il /0.rb Secret
Last active Feb 5, 2016

What would you like to do?
[WP/1489] 앱 아이콘에 앱 버전, 빌드 번호 등의 정보를 표시하는 방법
desc "badge 를 이용하여 앱 아이콘에 배지를 추가"
private_lane :lane_add_badge do
badge(
shield: "#{@app_version}-#{@build_number}-orange",
no_badge: true
)
end
desc "reset_git_repo 를 이용하여 앱 아이콘을 이전 상태로 복구"
private_lane :lane_remove_badge do
# badge - Add a badge to your iOS app icon.
# https://github.com/HazAT/badge
# https://github.com/HazAT/badge/blob/master/lib/badge/runner.rb
path = Pathname.new(Dir.pwd).dirname
app_icons = Dir.glob("#{path}/**/*.appiconset/*.{png,PNG}")
reset_git_repo(
force: true,
files: app_icons
)
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment