3
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

[Salesforce DX] 組織のインストール済パッケージのメタデータをぱぱっと取得する

Last updated at Posted at 2018-01-30

Salesforce DX を使って手早く既存組織のインストール済パッケージのメタデータを取得する方法です。

sfdx-get-org-metadata.sh

# エイリアス MyOrg に既存組織を紐付ける(コマンド実行後にブラウザが立ち上がるので紐付ける組織にログインする
$ sfdx force:auth:web:login -a MyOrg

# Salesforce Dx のプロジェクトをプロジェクト名 MyProject で作成
$ sfdx force:project:create --projectname MyProject

$ cd MyProject

# メタデータを出力するディレクトリを作る
$ mkdir mdapipkg

# パッケージ MyPackageName のメタデータを取得
$ sfdx force:mdapi:retrieve -s -r ./mdapipkg -u MyOrg -p MyPackageName
Retrieving source...

=== Status
Status:  InProgress
jobid:  09S10000001YS9oEAG


=== Result
Status:  Succeeded
jobid:  09S10000001YS9oEAG

Wrote retrieve zip to /path/to/MyProject/mdapipkg/unpackaged.zip.

mdapipkg ディレクトリに作成される unpackaged.zip にメタデータが入っています。

3
4
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
4

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?