Skip to content

feat: project clone#244

Merged
benPearce1 merged 2 commits intomainfrom
feat/clone-project
Jun 8, 2023
Merged

feat: project clone#244
benPearce1 merged 2 commits intomainfrom
feat/clone-project

Conversation

@benPearce1
Copy link
Copy Markdown
Contributor

@benPearce1 benPearce1 commented Jun 5, 2023

Depends upon OctopusDeploy/go-octopusdeploy#194

octopus project clone --space "step usages" --name "project 12" --source "project 11" -d "new description" -g "project group"

Successfully cloned project 'project 12' (project-12), with lifecycle 'Lifecycles-183' in project group 'ProjectGroups-203'.
View this project on Octopus Deploy: http://localhost:8065/app#/Spaces-143/projects/Projects-2652

Automation Commands:
octopus project clone --name 'project 12' --source 'project 11' --group 'project group' --lifecycle 'Default Lifecycle' --no-prompt

mirroring the project create behaviour for project groups

octopus project clone --space "step usages" --name "project 8" --source "project 4" -d "new description"
? You have not specified a Project group for this project. Please select one: <Create New>
? Project Group Name project group
? Project Group Description

Successfully created project group project group.
View this project group on Octopus Deploy: http://localhost:8065/app#/Spaces-143/projectGroups/ProjectGroups-203

Successfully cloned project 'project 8' (project-8), with lifecycle 'Lifecycles-183' in project group 'ProjectGroups-203'.
View this project on Octopus Deploy: http://localhost:8065/app#/Spaces-143/projects/Projects-2648

Automation Commands:
octopus project-group create --name 'project group' --no-prompt
octopus project clone --name 'project 8' --source 'project 4' --group 'project group' --lifecycle 'Default Lifecycle' --no-prompt

prompt for project group and lifecycle

octopus project clone --space "step usages" --name "project 13" --source "project 11" -d "new description"
? You have not specified a Lifecycle for this project. Please select one: second lifecycle
? You have not specified a Project group for this project. Please select one: Default Project Group

Successfully cloned project 'project 13' (project-13), with lifecycle 'Lifecycles-203' in project group 'ProjectGroups-183'.
View this project on Octopus Deploy: http://localhost:8065/app#/Spaces-143/projects/Projects-2655

Automation Commands:
octopus project clone --name 'project 13' --source 'project 11' --group 'Default Project Group' --lifecycle 'second lifecycle' --no-prompt

errors returned from api

octopus project clone --space "step usages" --name "project 13" --source "project 11" -d "new description" --no-prompt
octopus deploy api returned an error on endpoint /api/Spaces-143/projects?clone=Projects-2651 - [A project with this name already exists. Please choose a different name.]

@benPearce1 benPearce1 requested a review from domenicsim1 June 5, 2023 05:28
Copy link
Copy Markdown
Collaborator

@domenicsim1 domenicsim1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good stuff, update go.mod for octopus SDK, and its good to go.

@benPearce1 benPearce1 merged commit f6a0ba5 into main Jun 8, 2023
@benPearce1 benPearce1 deleted the feat/clone-project branch June 8, 2023 05:46
This was referenced Jul 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants