title: Upload a variable named file via CURL command line
body: <p>I am trying to upload a file to a server using <code>Curl command line</code> tool. File which is uploaded is generated by a build tool so its name is variable and depends upon the version of the project.</p>
  
  <p>For example: </p>
  
  <blockquote>
    <p>File to be uploaded has name: puppet-14.1.6-snapshot.zip // where 14.1.6 is the version of project</p>
  </blockquote>
  
  <p><strong>Here is my (working) CURL command:</strong></p>
  
  <blockquote>
    <p>curl -u admin:admin -F file=@"target/puppet-14.1.6-snapshot.zip" -F name="puppet-core-pkg" -F force=true -F install=true <a href="http://myserver.com:4502/service.jsp" rel="nofollow">http://myserver.com:4502/service.jsp</a></p>
  </blockquote>
  
  <p>The above call works perfectly but I am trying to find an alternative via which i do not need to change the file parameter every time a new version of project goes out.</p>
  
  <p>I have already tried these two</p>
  
  <pre><code>file=@"target/puppet-*-snapshot.zip" //Does not work
  file=@"target/puppet-[*]-snapshot.zip" //Does not work
  </code></pre>
  
  <p><strong>Is it possible to use some regex and upload the file which matched the given regex ?</strong></p>