< Back

Publish-DevartDatabaseProject

Mon Jan 13, 2020 7:08 pm

NAME Publish-DevartDatabaseProject



SYNOPSIS

Publish DatabaseProject as NuGet package to the NuGet repository.





SYNTAX

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

<SwitchParameter>] [<CommonParameters>]





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.





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,

OutBuffer, PipelineVariable, and OutVariable. For more information, see

about_CommonParameters (https:/go.microsoft.com/fwlink/?LinkID=113216).



INPUTS



OUTPUTS

System.Boolean





---------- EXAMPLE 1 ----------



Set-DevartPackageInfo -Project $databaseProject -Id Devart.DbForge.DevOpsAutomation.ScriptFolder -Version

1.0.0-beta

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





RELATED LINKS

Online help:

https://docs.devart.com/devops-automati ... oject.html