Skip to content
This repository was archived by the owner on Aug 16, 2025. It is now read-only.

✨ Upgrade to new DevOps design#30

Merged
pleonex merged 3 commits intomainfrom
feature/upgrade-v1
Nov 16, 2023
Merged

✨ Upgrade to new DevOps design#30
pleonex merged 3 commits intomainfrom
feature/upgrade-v1

Conversation

@pleonex
Copy link
Copy Markdown
Owner

@pleonex pleonex commented Oct 24, 2023

Description

Re-design of the template project to upgrade to latest best-practices and technologies. It follows the work from pleonex/PleOps.Cake#67

Migration steps

There are changes in almost every file of the template repository. The build system while it keeps the same architecture its technologies suffered major structural changes. The easier migration step is to repeat the project setup steps. Otherwise, the changes were:

Build system

  • Build tool dependencies now defined in .config/dotnet-tools.json.
    • Remove dotnet-cake
    • Add 'gitversion.tool', 'thirdlicense', 'dotnet-reportgenerator-globaltool', 'docfx', 'gitreleasemanager.tool'
    • Now you have control over their updates. Unless they change the CLI, you can safely update.
  • Update Directory.Build.props
    • Set IsPackable and IsPublishable to false.
    • Fix the sourcelink settings
    • Set AnalysisLevel if you want
  • Remove the RunConfiguration from Tests.runsettings
  • For public libraries or dotnet tool (projects that generates nugets) set IsPackable to true
  • For apps to publish to github release, set IsPublishable to true and remove the RuntimeIDentifier and RuntimeIdentifiers now they are set in the build system
  • Take this opportunity to review if you want to enable new features like ImplicitUsings, Nullable and add Description.
  • Probably you want to set <GenerateDocumentationFile>false</GenerateDocumentationFile> in the test libs
  • Put the new template of build sytem in build/orchestrator
    • Adjust according to your old build.cake. Remove it afterwards.
    • Only you need to define executables, not libs or test projects.
    • Alternatevely you can put a build.csx dotnet-script in your repo root

Docs

  • Update README with new build and release instructions
  • Public docs has its own README instead of including, with a reduced subset of content not target to contributors but users
  • Update CONTRIBUTING.md to include the developer certificate of origin
    • This file is not included anymore in public docs as it's intended for devs only
  • Add the new .gitignore files to docs/ and docs/api
  • The default proposed layout has changed, check-out the new TOC files
  • Update docfx.json, several fields have changed:
    • We can reference again projects to their .csproj instead of dll
    • New properties for generating API docs
    • Structure to include files and resources has changed. Each subfolder can have an images or resources subfolder.
    • PDF support was removed from the default template
    • New sitemap properties
    • filter_config.yml is not required anymore as the issues were fixed
    • global_metadata.json is now included in main docfx.json
  • Include the docs/template folder with adjustments to the default template.
  • Update docs/template/public/main.js with the URL to the GitHub repo

CI

  • PR and issues templates were updated. Copy them from .github folder
  • Update the version of the CI tasks and .NET version (.github/workflows).
  • Change the pipeline to run the new .NET build system project instead of donet cake.
  • Add the tasks to publish the documentation page to the CI pipeline.
    • It requires: GitHub project settings -> Pages -> Source: Deploy from GitHub actions

IDEs

  • .editorconfig includes rules for csproj files and new C# code analyzers. Update it.
  • .editorconfig was moved to the root to include rules for other languages, and .prettierrc was also added. Remove it from src/
    • Remove the prettier.proseWrap VSCode setting as we have it in .prettierrc now
  • Remove Prettier settings from .vscode/settings.json
  • Update .vscode/tasks.json to build using the new build system project
  • If you don't want to maintain them anymore, remove the .devcontainer
    • For a basic .NET projects there isn't any need to have a docker dev container

This closes #29

@pleonex pleonex added the enhancement New feature or request label Oct 24, 2023
@pleonex pleonex self-assigned this Oct 24, 2023
@pleonex pleonex added this to the vNext milestone Nov 16, 2023
@pleonex pleonex marked this pull request as ready for review November 16, 2023 17:19
@pleonex pleonex merged commit 22cd545 into main Nov 16, 2023
@pleonex pleonex deleted the feature/upgrade-v1 branch November 16, 2023 17:19
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Update repository to new Frosting recipe

1 participant