function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
hisrinuhisrinu 

How to upload static Resources using ANT Tool?


Hi,
 
  Is there any way to upload the static resources through ant?
  If yes can you just share what is the name attribute you are using for that.
  I tried with StaticResource, I am getting blank xml. So any suggestions will be highly appreciated.



hisrinuhisrinu
Hi,

I figured out using "StaticResource" we can get the static resources.
I don't know it is working fine for * not for specific ones.
Vivek JoshiVivek Joshi
Hi,

This also works with specific ones. The thing that matters here is the api version which must be correct:

<?xml version="1.0" encoding="UTF-8"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
    <types>
        <members>Name_Of_The_Static_Resource</members>
        <name>StaticResource</name>
    </types>
    <version>27.0</version> 
</Package>

If the version specified is correct. The resources would be pulled easily.
P5P5
The static resources can be migrated using the following package.xml file.
 
<?xml version="1.0" encoding="UTF-8"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
    <types>
        <members>Static_Resource_Name</members>
        <name>StaticResource</name>
    </types>
    <version>27.0</version> 
</Package>