micro-elements - MicroElements.DevOps 1.11.0

DevOps scripts for CI and CD

Main features

  • Based on CakeBuild
  • Supported OS: Windows, Linux
  • Supported CI: Travis, AppVeyor, Jenkins, any other
  • C# project generation or initialization with CI and CD included
  • Only two files: build.ps1 and build.sh. All other files can be generated
  • No need to maintain your own build scripts
  • You can customize and add own tasks if you need

PM> Install-Package MicroElements.DevOps -Version 1.11.0 -Source https://www.myget.org/F/micro-elements/api/v3/index.json

Copy to clipboard

> nuget.exe install MicroElements.DevOps -Version 1.11.0 -Source https://www.myget.org/F/micro-elements/api/v3/index.json

Copy to clipboard

> dotnet add package MicroElements.DevOps --version 1.11.0 --source https://www.myget.org/F/micro-elements/api/v3/index.json

Copy to clipboard
<PackageReference Include="MicroElements.DevOps" Version="1.11.0" />
Copy to clipboard
source https://www.myget.org/F/micro-elements/api/v3/index.json

nuget MicroElements.DevOps  ~> 1.11.0
Copy to clipboard

> choco install MicroElements.DevOps --version 1.11.0 --source https://www.myget.org/F/micro-elements/api/v2

Copy to clipboard
Import-Module PowerShellGet
Register-PSRepository -Name "micro-elements" -SourceLocation "https://www.myget.org/F/micro-elements/api/v2"
Install-Module -Name "MicroElements.DevOps" -RequiredVersion "1.11.0" -Repository "micro-elements" 
Copy to clipboard

MicroElements.DevOps

DevOps scripts for CI and CD

Statuses

License NuGetVersion NuGetDownloads MyGetVersion

Travis AppVeyor Coverage Status

Gitter

Main features

  • Based on CakeBuild
  • Supported OS: Windows, Linux
  • Supported CI: Travis, AppVeyor, Jenkins, any other
  • C# project generation or initialization with CI and CD included
  • Only two files: build.ps1 and build.sh. All other files can be generated
  • No need to maintain your own build scripts
  • You can customize and add own tasks if you need

Getting started

1. Download bootstrap script

Open a new PowerShell window and run the following command.

Invoke-WebRequest https://raw.githubusercontent.com/micro-elements/MicroElements.DevOps/master/resources/build.ps1 -OutFile build.ps1

2. Run Init script

Run target Init

./build.ps1 -Target "Init"

Result

  • generated project
  • generated test project
  • travis.yml
  • appveyor.yml
  • build.ps1
  • build.sh
  • CHANGELOG.md
  • README.md
  • common.props
  • version.props
  • src/Directory.Build.props
  • test/Directory.Build.props
  • stylecop integration
  • Readme statuses generated

3. Project initialization

  • Fill common.props: Description, PackageTags, PackageIconUrl (other attributes was filled autpmatically by init script)

4. Usage

Local build

Run target Default

./build.ps1 -Target "Default"

Travis CI

Add file .travis.yml to project

language: csharp
mono: none
dotnet: 2.1.300
os:
  - linux
before_script:
  - chmod a+x ./build.sh
script:
  - ./build.sh --target=Travis --verbosity=normal

Other CI

Run shell script: ./build.sh --target=Travis

Tasks

Init

Initializes project structure and adds all needed files

Runs:

Default

Builds projects and runs tests

Runs:

Travis

Does versioning, builds projects, runs tests creates and uploads artifacts

Runs:

AppVeyor

Builds, tests and uploads test results to appVeyor

Runs:

CreateProjectStructure

TODO: all tasks

Features

Customize build

add cake.build file in root of your project TODO: samples

Concepts

  • ScriptParam
  • ScriptArgs
  • Value chains
  • Conventions

ScriptParam

  • props
  • get value chain

ScriptArgs

Param Description DefaulValue
SrcDir Sources directory. Contains projects. src

1.11.0

  • Updated libs

1.10.0

  • Updated libs
  • Changed: Cake.Coverlet version fixed to 2.4.2

1.9.1

  • Changed: Cake.Coverlet version fixed to 2.2.1
  • Changed: coverlet.msbuild updated to 2.6.1
  • Changed: ArgumentOrEnvVar compares arg name ignoring case

1.9.0

  • UploadPackagedIfNeeded with detailed information
  • UploadPackagedIfNeeded uses ForceUploadPackages
  • GetTestProjectsFunc can be used to override default test project search

1.8.1

  • Fixed IsPullRequest evaluation for travis

Full release notes can be found at: https://github.com/micro-elements/MicroElements.DevOps.git/blob/master/CHANGELOG.md

Owners

Alexey Petryashev

Authors

alexey.petriashev

Project URL

https://github.com/micro-elements/MicroElements.DevOps

License

MIT

Tags

DevOps cake buildScript CI CD

Info

46 total downloads
2 downloads for version 1.11.0
Download (37.22 KB)
Found on the current feed only

Package history

Version Size Last updated Downloads Mirrored?
1.11.0 37.22 KB Sun, 31 May 2020 20:15:08 GMT 2
1.10.0 35.28 KB Sun, 31 May 2020 16:15:15 GMT 3
1.9.1 37.11 KB Mon, 03 Jun 2019 12:11:33 GMT 2
1.9.0 37.03 KB Tue, 23 Apr 2019 20:12:33 GMT 2
1.8.1 36.73 KB Mon, 21 Jan 2019 21:57:14 GMT 0
1.8.0 36.78 KB Mon, 21 Jan 2019 20:17:47 GMT 1
1.7.3 36.65 KB Sun, 23 Dec 2018 18:44:33 GMT 1
1.7.2 36.69 KB Sat, 22 Dec 2018 20:50:39 GMT 1
1.7.1 36.68 KB Tue, 18 Dec 2018 21:01:58 GMT 1
1.7.0 36.78 KB Mon, 22 Oct 2018 21:46:36 GMT 1
1.6.0 36.72 KB Sun, 12 Aug 2018 20:41:31 GMT 1
1.5.0 37.69 KB Tue, 07 Aug 2018 21:29:58 GMT 1
1.4.1 35.63 KB Fri, 03 Aug 2018 20:15:42 GMT 1
1.4.0 35.59 KB Thu, 02 Aug 2018 22:04:24 GMT 2
1.3.0 34.52 KB Mon, 23 Jul 2018 19:31:35 GMT 2
1.2.0 31.72 KB Sat, 21 Jul 2018 12:15:56 GMT 1
1.1.1 30.39 KB Tue, 17 Jul 2018 22:41:14 GMT 0
1.1.0 30.37 KB Tue, 17 Jul 2018 20:34:15 GMT 1
1.0.0 29.16 KB Sat, 14 Jul 2018 21:46:14 GMT 1
1.0.0-beta.2 27.85 KB Tue, 10 Jul 2018 15:43:19 GMT 1
1.0.0-beta.1 27.8 KB Mon, 09 Jul 2018 21:32:38 GMT 1
0.6.0-beta.1 23.2 KB Wed, 20 Jun 2018 21:20:24 GMT 0
0.5.0 23.19 KB Mon, 18 Jun 2018 16:53:13 GMT 1
0.5.0-rc.3 23.2 KB Mon, 18 Jun 2018 16:29:10 GMT 1
0.5.0-rc.2 23.03 KB Mon, 18 Jun 2018 13:47:27 GMT 1
0.5.0-rc.1 21.57 KB Thu, 14 Jun 2018 14:57:51 GMT 2
0.3.0 10.51 KB Sat, 12 May 2018 22:25:16 GMT 4
0.2.0 9.22 KB Sat, 12 May 2018 16:51:30 GMT 11