Unpack the Retrieved Zip File
The force:mdapi:retrieve
operation left us with a Zip file containing the metadata from our managed package. We need to unzip that file before we can do anything with it.
In this exercise, you will…
- Use the CLI to unpack the retrieved zip file (MacOS/Linux Only)
- Alternatively, use an external program to unpack the retrieved zip file (MacOS/Linux/Windows)
Use the CLI to unpack the retrieved zip file (MacOS/Linux Only)
Developers running MacOS and Linux have access to command line tools that make it very easy to unpack a Zip file.
On MacOS or Linux, execute this command:
unzip ./mdapi-source/unpackaged.zip -d ./mdapi-source/original-package
After executing the above, your terminal should look something like this:

Alternatively, use an external program to unpack the retrieved zip file (MacOS/Linux/Windows)
If you don’t want to use (or don’t have) the unzip
command line tool, you can open your system’s file browser app at the location of the unpackaged.zip
file, allowing you to use the unzip/unpack tool you that are used to using.
- Make sure you’ve already performed the
force:mdapi:retrieve
command. - In the File Explorer, right-click on
unpackaged.zip
. - Click the Reveal in Finder (Mac) or Reveal in Explorer (Windows) menu option.

Once you’ve found your file outside of VS Code, you can use whatever application you normally do for unzipping/unpacking Zip files.
Critical: If you unpack your Zip file without using the command provided above, you MUST make sure that the contents are placed in a folder named original-package
, inside of the mdapi-source
directory in your my-managed-package
project.