mirror of
https://github.com/Ellpeck/MLEM.git
synced 2024-11-27 15:08:33 +01:00
Compare commits
No commits in common. "289e35fc91edf223af442322703c3e01c3dd1b1f" and "40a697a96c49635daeaad72700b5ad888d3eec32" have entirely different histories.
289e35fc91
...
40a697a96c
6 changed files with 58 additions and 45 deletions
|
@ -113,6 +113,6 @@ resharper_xmldoc_attribute_indent = align_by_first_attribute
|
||||||
resharper_xmldoc_attribute_style = on_single_line
|
resharper_xmldoc_attribute_style = on_single_line
|
||||||
resharper_xmldoc_pi_attribute_style = on_single_line
|
resharper_xmldoc_pi_attribute_style = on_single_line
|
||||||
|
|
||||||
[{*.md,*.yaml,*.yml}]
|
[*.md]
|
||||||
trim_trailing_whitespace = false
|
trim_trailing_whitespace = false
|
||||||
indent_size = 2
|
indent_size = 2
|
||||||
|
|
|
@ -1,16 +0,0 @@
|
||||||
steps:
|
|
||||||
build:
|
|
||||||
image: runmymind/docker-android-sdk:ubuntu-standalone
|
|
||||||
commands:
|
|
||||||
# install xvfb to allow for graphics-dependent tests
|
|
||||||
- apt-get update && apt-get install -y --no-install-recommends xauth xvfb openjdk-11-jdk
|
|
||||||
# install dotnet
|
|
||||||
- curl -sSL https://dot.net/v1/dotnet-install.sh | bash /dev/stdin --version 7.0.305
|
|
||||||
- export DOTNET_ROOT=$HOME/.dotnet
|
|
||||||
- export PATH=$PATH:$DOTNET_ROOT:$DOTNET_ROOT/tools
|
|
||||||
# run cake
|
|
||||||
- dotnet tool restore
|
|
||||||
- xvfb-run -a dotnet cake --target Publish --branch $CI_COMMIT_BRANCH
|
|
||||||
secrets:
|
|
||||||
- nuget_key
|
|
||||||
- baget_key
|
|
|
@ -1,16 +0,0 @@
|
||||||
steps:
|
|
||||||
document:
|
|
||||||
image: mcr.microsoft.com/dotnet/sdk:7.0.305
|
|
||||||
commands:
|
|
||||||
- dotnet tool restore
|
|
||||||
- dotnet cake --target Document --branch $CI_COMMIT_BRANCH
|
|
||||||
deploy:
|
|
||||||
image: debian:latest
|
|
||||||
when:
|
|
||||||
- event: [push, manual]
|
|
||||||
branch: release
|
|
||||||
commands:
|
|
||||||
- rm -rfv /var/www/MLEM/*
|
|
||||||
- cp -rv Docs/_site/. /var/www/MLEM/
|
|
||||||
volumes:
|
|
||||||
- /var/www/MLEM:/var/www/MLEM
|
|
|
@ -1,8 +1,6 @@
|
||||||
- name: Home
|
|
||||||
href: /
|
|
||||||
- name: Tutorials
|
- name: Tutorials
|
||||||
href: articles/
|
href: articles/
|
||||||
- name: API Documentation
|
- name: API Documentation
|
||||||
href: api/
|
href: api/
|
||||||
- name: Changelog
|
- name: Changelog
|
||||||
href: ../CHANGELOG.md
|
href: ../CHANGELOG.md
|
48
Jenkinsfile
vendored
Normal file
48
Jenkinsfile
vendored
Normal file
|
@ -0,0 +1,48 @@
|
||||||
|
pipeline {
|
||||||
|
agent none
|
||||||
|
stages {
|
||||||
|
stage('Cake') {
|
||||||
|
agent any
|
||||||
|
stages {
|
||||||
|
stage('Submodules') {
|
||||||
|
steps {
|
||||||
|
sh 'git submodule update --init --recursive --force'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Build') {
|
||||||
|
steps {
|
||||||
|
sh 'dotnet tool restore'
|
||||||
|
// we use xvfb to allow for graphics-dependent tests
|
||||||
|
sh 'xvfb-run -a dotnet cake --target Publish --branch ' + env.BRANCH_NAME
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Document') {
|
||||||
|
steps {
|
||||||
|
sh 'dotnet cake --target Document --branch ' + env.BRANCH_NAME
|
||||||
|
stash includes: 'Docs/_site/**', name: 'site'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
post {
|
||||||
|
always {
|
||||||
|
nunit testResultsPattern: '**/TestResults.xml'
|
||||||
|
cobertura coberturaReportFile: '**/coverage.cobertura.xml'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
stage('Publish Docs') {
|
||||||
|
when { branch 'release' }
|
||||||
|
agent { label 'web' }
|
||||||
|
options { skipDefaultCheckout() }
|
||||||
|
steps {
|
||||||
|
unstash 'site'
|
||||||
|
sh 'rm -rf /var/www/MLEM/*'
|
||||||
|
sh 'cp Docs/_site/** /var/www/MLEM/ -r'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
environment {
|
||||||
|
BAGET = credentials('3db850d0-e6b5-43d5-b607-d180f4eab676')
|
||||||
|
NUGET = credentials('e1bf7f6c-6047-4f7e-b639-15240a8f8351')
|
||||||
|
}
|
||||||
|
}
|
17
build.cake
17
build.cake
|
@ -1,5 +1,5 @@
|
||||||
#addin nuget:?package=Cake.DocFx&version=1.0.0
|
#addin nuget:?package=Cake.DocFx&version=1.0.0
|
||||||
#tool dotnet:?package=docfx&version=2.70.3
|
#tool dotnet:?package=docfx&version=2.67.5
|
||||||
|
|
||||||
// this is the upcoming version, for prereleases
|
// this is the upcoming version, for prereleases
|
||||||
var version = Argument("version", "6.2.0");
|
var version = Argument("version", "6.2.0");
|
||||||
|
@ -9,12 +9,11 @@ var config = Argument("configuration", "Release");
|
||||||
var serve = HasArgument("serve");
|
var serve = HasArgument("serve");
|
||||||
|
|
||||||
Task("Prepare").Does(() => {
|
Task("Prepare").Does(() => {
|
||||||
DotNetWorkloadInstall("android");
|
|
||||||
DotNetRestore("MLEM.sln");
|
DotNetRestore("MLEM.sln");
|
||||||
DotNetRestore("MLEM.FNA.sln");
|
DotNetRestore("MLEM.FNA.sln");
|
||||||
|
|
||||||
if (branch != "release") {
|
if (branch != "release") {
|
||||||
var buildNum = EnvironmentVariable("CI_PIPELINE_NUMBER");
|
var buildNum = EnvironmentVariable("BUILD_NUMBER");
|
||||||
if (buildNum != null)
|
if (buildNum != null)
|
||||||
version += "-ci." + buildNum;
|
version += "-ci." + buildNum;
|
||||||
}
|
}
|
||||||
|
@ -50,20 +49,20 @@ Task("Pack").IsDependentOn("Test").Does(() => {
|
||||||
});
|
});
|
||||||
|
|
||||||
Task("Push").WithCriteria(branch == "main" || branch == "release").IsDependentOn("Pack").Does(() => {
|
Task("Push").WithCriteria(branch == "main" || branch == "release").IsDependentOn("Pack").Does(() => {
|
||||||
DotNetNuGetPushSettings settings;
|
NuGetPushSettings settings;
|
||||||
if (branch == "release") {
|
if (branch == "release") {
|
||||||
settings = new DotNetNuGetPushSettings {
|
settings = new NuGetPushSettings {
|
||||||
Source = "https://api.nuget.org/v3/index.json",
|
Source = "https://api.nuget.org/v3/index.json",
|
||||||
ApiKey = EnvironmentVariable("NUGET_KEY")
|
ApiKey = EnvironmentVariable("NUGET")
|
||||||
};
|
};
|
||||||
} else {
|
} else {
|
||||||
settings = new DotNetNuGetPushSettings {
|
settings = new NuGetPushSettings {
|
||||||
Source = "https://nuget.ellpeck.de/v3/index.json",
|
Source = "https://nuget.ellpeck.de/v3/index.json",
|
||||||
ApiKey = EnvironmentVariable("BAGET_KEY")
|
ApiKey = EnvironmentVariable("BAGET")
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
settings.SkipDuplicate = true;
|
settings.SkipDuplicate = true;
|
||||||
DotNetNuGetPush("**/MLEM*.nupkg", settings);
|
NuGetPush(GetFiles("**/MLEM*.nupkg"), settings);
|
||||||
});
|
});
|
||||||
|
|
||||||
Task("Document").Does(() => {
|
Task("Document").Does(() => {
|
||||||
|
|
Loading…
Reference in a new issue