More than 5 years have passed since last update.
やり方
UUIDの抽出
$ xmllint <(security cms -D -i your.mobileprovision) --xpath '/plist/dict/key[text()="UUID"]/following-sibling::string[position()=1]/text()'
Nameの抽出
$ xmllint <(security cms -D -i your.mobileprovision) --xpath '/plist/dict/key[text()="Name"]/following-sibling::string[position()=1]/text()'
解説
- provisioning profileはそのままだと、plutilコマンドなどでparseできない。
- securityコマンドで一度textに変換する。
- 変換結果は Process Substitution を用いて標準出力からファイルディスクリプタとしてかませる
- xmllintのxpathオプションで対象のKeyの名前のノードの兄弟ノードのテキストを抽出する。
Why not register and get more from Qiita?
- We will deliver articles that match you
By following users and tags, you can catch up information on technical fields that you are interested in as a whole
- you can read useful information later efficiently
By "stocking" the articles you like, you can search right away
Sign upLogin