Publish-DevartDatabaseProject

Synopsis

Publishes DatabaseProject as a NuGet package to a NuGet repository.

Description

If AutoIncrementVersion parameter is set to true and the latest version of NuGet package greater of equal the specified version - the latest version will be incremented; otherwise the specified version will be used.

Syntax

Publish-DevartDatabaseProject -Project <object> -Repository <string> [-ApiKey <string>] [-AutoIncrementVersion <SwitchParameter>] [<CommonParameters>]

Parameters

-Project <object>

Instance of a DatabaseProject object to be published or a package file name. This object is produced by the Invoke-DevartDatabaseBuild and Set-DevartPackageInfo cmdlets.

Required? true

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false

-Repository <string>

NuGet feed that the database build artifact will be published to. It must be a valid URL or local path to a NuGet feed.

Required? true

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false

-ApiKey <string>

In order to authenticate a client against a NuGet repository, NuGet uses an API key for deployment requests.

The API key is acts as an alias for the user account, so the same API key is used for all NuGet repositories within the repository manager.

Required? false

Position? named

Default value

Accept pipeline input? false

Accept wildcard characters? false

-AutoIncrementVersion <SwitchParameter>

Use this parameter to auto increment package version if a package with the specified version already exists on the NuGet repository. This parameter will be ignored if the Project is not an object of the DatabaseProject.

Required? false

Position? named

Default value False

Accept pipeline input? false

Accept wildcard characters? false

<CommonParameters>

This cmdlet supports the common parameters: Verbose, Debug, ErrorAction, ErrorVariable, WarningAction, WarningVariable, InformationAction, InformationVariable, OutBuffer, PipelineVariable, and OutVariable. For more information, see About CommonParameters.

Outputs

System.Boolean (returns true on success and false otherwise)

Examples

---------- EXAMPLE 1 ----------
Set-DevartPackageInfo -Project $databaseProject -Id Devart.DbForge.DevOpsAutomation.ScriptFolder -Version 1.0.0
Publish-DevartDatabaseProject -Project $databaseProject -Repository C:/NuGetRepository -AutoIncrementVersion
---------- EXAMPLE 2 ----------
Publish-DevartDatabaseProject -Project "C:/Test/Test.DevOpsAutomation.Database.3.0.9.nupkg" -Repository C:/NuGetRepository

Want to Find out More?

Overview

Overview

Take a quick tour to learn all about the key benefits delivered by dbForge DevOps Automation for SQL Server.
Request a demo

Request a demo

If you consider employing the DevOps Automation for your business, request a demo to see it in action.
Ready to start using dbForge DevOps Automation for SQL Server?