curl / Mailing Lists / curl-users / Single Mail
Buy commercial curl support. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder Daniel himself.

Re: Reference upload glob pieces in output filename

From: Daniel Stenberg via curl-users <curl-users_at_lists.haxx.se>
Date: Wed, 22 Apr 2026 09:53:44 +0200 (CEST)

On Wed, 22 Apr 2026, Stefan Eissing wrote:

>> curl -T 'file{1,2,3}' https://upload.example/ -o 'response-!1'
>>
>> Maybe we can think of a better way?
>
> Have not looked at the internals. As a user, I would expect `-o 'save-#1' to
> also work for uploads.
>
> (I assume the #1 counter only counts url globs and not upload globs, but
> that is an implementation detail, or?)

Here's an example that shows why they need to be different (in some way):

   curl -T 'file{1,2,3}' https://upload.example/{this,that} -o 'response-!1-#1'

-- 
  / daniel.haxx.se || https://rock-solid.curl.dev
-- 
Unsubscribe: https://lists.haxx.se/mailman/listinfo/curl-users
Etiquette:   https://curl.se/mail/etiquette.html
Received on 2026-04-22