There can be situations that will require you to move your artifacts from the root location of a repository to a custom path or a folder in the same local repository. Should this need arise, it can be accomplished in two ways:
1. Through the Artifactory UI- Login to Artifactory and go to the Artifacts tab
- Select and expand the repository
- Right click the folder you’d like to move and select Move
- In the dialog box that opens, tick the Move to a custom path option, enter your desired path, and click Move
2. Through the REST API
- Use the Move Item REST API to move an artifact or a folder to a new location within the same repository. Here’s an example of what the command line should look like:
curl -X POST -u{user}:{password} "http://{Artifactory_URL}:{Artifactory_Port}/artifactory/api/move/{Repository_name}/{Folder_name}?to=/{same repository name}/{the new name}"
The same steps may be followed to move an artifact or a folder to a different or newly-created local repository.
Published: May 13, 2019
Last updated: Mar. 15, 2021
Keywords: moving artifacts, moving folders