Copying Files with Certain File Extensions using AzCopy Task in Azure DevOps

 I was trying to copy only certain files within a directory to Azure Storage Account instead of the whole directory content.

The files that I tried to copy are those ends with .zip, .tag.gz, and .py. AzCopy support wildcard on the source, so I would like to do something like this:

azcopy copy C:\{directory}\[*.zip|*.tar.gz|*.py] ...

I found out later that there's --include-pattern option, so this works:

azcopy copy C:\{directory}\* --include-pattern *.zip;*.tar.gz;*.py

Comments

Popular posts from this blog

Sentinel One Strikes Again. No internet connection. Uninstall Sentinel One Agent.

A2 Hosting Let's Encrypt Can't Install Certificate on ASP.NET Core Application

NuGet Package Reference NU6105 Publish Error