2

I am new to VS Code and trying to copy Permission Set permissions into a Profile so that we don't have too many permission sets. I thought rather than checking in SF and clicking back and forth I can do it from here. Im thinking I can copy the permissions from the permission set and then paste it into the profile and update it from VS Code.

This permission set doesn't tell me what permissions it has (see below) enter image description here

This permission set on the other hand does.

enter image description here

Why does one show me what permission it has and the other one doesn't?

Thank you

2 Answers 2

2

The first Permission Set does not permission any components.

If in your org this Permission Set actually does provide permissions, your local copy of the metadata may be out of date.

Unlike Profiles, retrieving Permission Sets does pull the entire component regardless of what other metadata is included in the manifest. That Permission Set is just empty.

1
  • Took the words right out of my answer box 😁.
    – sfdcfox
    Commented Apr 22, 2022 at 3:06
2

I'd recommend before doing the copy paste, to do a retrieve of the Profiles & Permission Sets.

But bare in mind that if you do it from the VS Code interface, with right click on the folder and retrieve, this wont download the FLS.

enter image description here

It's better to go to CLI and run something like this

sfdx force:source:retrieve -m CustomObject,Profile,PermissionSet

That way while retrieving the custom objects and fields it will also get the Profile & Permission Sets with the Object & Field Security

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .