Commit adafaee0 authored by leoylung's avatar leoylung Committed by Todd Volkert

Remove duplicated assets under /pkg/data (#20728)

Require componentName to ensure assets are placed under /pkg/data/<component-name>
parent bab0ce97
......@@ -27,6 +27,7 @@ const List<String> _kRequiredOptions = <String>[
_kOptionPackages,
_kOptionAsset,
_kOptionAssetManifestOut,
_kOptionComponentName,
];
Future<Null> main(List<String> args) {
......@@ -89,10 +90,7 @@ Future<Null> writeFuchsiaManifest(AssetBundle assets, String outputBase, String
final libfs.IOSink outFile = destFile.openWrite();
for (String path in assets.entries.keys) {
outFile.write('data/$path=$outputBase/$path\n');
if (componentName != null && componentName.isNotEmpty) {
outFile.write('data/$componentName/$path=$outputBase/$path\n');
}
outFile.write('data/$componentName/$path=$outputBase/$path\n');
}
await outFile.flush();
await outFile.close();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment