In our pipeline we try to keep a mirrored setup between our actual game assets (*.png, *.fbx etc) and source assets (*.ma, *.psd etc) So for instance .../assets/images/foo.png would have a source file located in .../assets_source/images/foo.psd. But since having a unique *.psd file for every single icon is a bit much, we also have single *.psd files that contain multiple assets.
Our exporter (https://maybedoublequotes.blogspot.com/2021/12/image-exporter-setup-and-tools.html) could then look at the layersets inside the *.psd file to determine the final output path. When exporting a layer or layerset, the path of the *.psd file is used as the base of the export path, adding the layersets of the selected layer or layersets as folders. This makes it possible to export a lot of files from the same *.psd to different locations on disk. But what if the source and assets are out of sync?