Skip to content

Commit

Permalink
Merge branch 'release/1.0.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
nils-a committed Mar 19, 2021
2 parents f50419d + c9830c6 commit d3d305c
Show file tree
Hide file tree
Showing 86 changed files with 4,291 additions and 384 deletions.
64 changes: 53 additions & 11 deletions .all-contributorsrc
Original file line number Diff line number Diff line change
@@ -1,13 +1,55 @@
{
"files": [
"README.md"
],
"imageSize": 100,
"commit": false,
"contributors": [],
"contributorsPerLine": 7,
"projectName": "CakeContrib.Guidelines",
"projectOwner": "cake-contrib",
"repoType": "github",
"repoHost": "https://github.com"
"files": [
"README.md"
],
"imageSize": 100,
"commit": false,
"contributors": [
{
"login": "AdmiringWorm",
"name": "Kim J. Nordmo",
"avatar_url": "https://avatars.githubusercontent.com/u/1474648?v=4",
"profile": "https://github.com/AdmiringWorm",
"contributions": [
"question",
"ideas"
]
},
{
"login": "Jericho",
"name": "Jericho",
"avatar_url": "https://avatars.githubusercontent.com/u/112710?v=4",
"profile": "https://github.com/Jericho",
"contributions": [
"bug",
"ideas"
]
},
{
"login": "nils-a",
"name": "Nils Andresen",
"avatar_url": "https://avatars.githubusercontent.com/u/349188?v=4",
"profile": "https://github.com/nils-a",
"contributions": [
"code",
"maintenance"
]
},
{
"login": "augustoproiete",
"name": "C. Augusto Proiete",
"avatar_url": "https://avatars.githubusercontent.com/u/177608?v=4",
"profile": "https://augustoproiete.net",
"contributions": [
"ideas",
"review"
]
}
],
"contributorsPerLine": 7,
"projectName": "CakeContrib.Guidelines",
"projectOwner": "cake-contrib",
"repoType": "github",
"repoHost": "https://github.com",
"skipCi": true
}
24 changes: 15 additions & 9 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,24 +2,30 @@ name: Build

on:
push:
branches:
- main
- develop
- "feature/**"
- "release/**"
- "hotfix/**"
tags:
- "*"
paths-ignore:
- "README.md"
pull_request:

jobs:
build:
runs-on: ${{ matrix.os }}
#mimic "skip_branch_with_pr: true", see https://github.community/t/duplicate-checks-on-push-and-pull-request-simultaneous-event/18012/4
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name != github.repository
strategy:
matrix:
os: [windows-latest, ubuntu-latest, macos-latest]
os: [ ubuntu-18.04, windows-2019, macos-10.15 ]

steps:
- uses: actions/checkout@v2.3.3
with:
fetch-depth: 0
ref: ${{ github.event.ref }}
- name: Checkout the repository
uses: actions/checkout@v2
- name: Fetch all tags and branches
run: git fetch --prune --unshallow
- name: Cache Tools
uses: actions/cache@v2
with:
Expand All @@ -31,7 +37,7 @@ jobs:
script-path: recipe.cake
target: CI
verbosity: Diagnostic
cake-version: 0.38.4
cake-version: 0.38.5
cake-bootstrap: true
# currently, Cake.Recipe does not upload artifacts when run on gh-actions
- name: Upload Issues
Expand All @@ -44,7 +50,7 @@ jobs:
BuildArtifacts/**/coverlet/*.xml
- name: Upload Packages
uses: actions/upload-artifact@v2
if: matrix.os == 'windows-latest'
if: runner.os == 'Windows'
with:
if-no-files-found: warn
name: package
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:
jobs:
analyze:
name: Analyze
runs-on: ubuntu-latest
runs-on: ubuntu-18.04

strategy:
fail-fast: false
Expand Down Expand Up @@ -49,7 +49,7 @@ jobs:
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main

- run: ./build.ps1
- run: ./build.ps1 --target=DotNetCore-Build
shell: pwsh

- name: Perform CodeQL Analysis
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/publishDocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

steps:
- name: checkout
uses: actions/checkout@v2.3.3 #https://github.com/actions/checkout
uses: actions/checkout@v2
with:
fetch-depth: 0 # GitVersion is somewhat irritated when fetch-depth is "1"....
ref: ${{ github.event.ref }}
Expand Down
7 changes: 5 additions & 2 deletions .github/workflows/updateToc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,18 @@ jobs:
generateTOCs:
name: Generate all TOCs
runs-on: ubuntu-latest
# "better" would be to check if GH_TOKEN is available
if: github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository

steps:
- uses: actions/checkout@v2.3.3
- uses: actions/checkout@v2
with:
fetch-depth: 0
ref: ${{ github.event.ref }}

- uses: technote-space/toc-generator@v2
- uses: technote-space/toc-generator@v4
with:
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
TARGET_PATHS: "."
TOC_TITLE: "## Table of Contents"
CREATE_PR: true
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,4 @@ config.wyam.*

# JetBrains Rider
.idea/
.history/
11 changes: 11 additions & 0 deletions GitReleaseManager.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@ create:
[nuget](https://nuget.org/packages/CakeContrib.Guidelines/{milestone}).
footer-includes-milestone: true
milestone-replace-text: "{milestone}"
include-sha-section: true
sha-section-heading: "SHA256 Hashes of the release artifacts"
sha-section-line-format: "- `{1}\t{0}`"
export:
include-created-date-in-title: true
created-date-string-format: yyyy-MM-dd
Expand All @@ -30,3 +33,11 @@ issue-labels-alias:
- name: security
header: Security
plural: Security
close:
use-issue-comments: true
issue-comment: |-
:tada: This issue has been resolved in version {milestone} :tada:
The release is available on:
- [GitHub Release](https://github.com/{owner}/{repository}/releases/tag/{milestone})
- [NuGet Package](https://www.nuget.org/packages/CakeContrib.Guidelines/{milestone})
Your **[GitReleaseManager](https://github.com/GitTools/GitReleaseManager)** bot :package::rocket:
22 changes: 21 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ Adds common guidelines to cake-contrib projects

- [Install](#install)
- [Guidelines](#guidelines)
- [Discussion](#discussion)
- [Maintainer](#maintainer)
- [Contributing](#contributing)
- [Contributors](#contributors)
Expand Down Expand Up @@ -42,6 +43,12 @@ See [NuGet](https://www.nuget.org/packages/CakeContrib.Guidelines/) for the curr

All [guidelines](https://cake-contrib.github.io/CakeContrib.Guidelines/guidelines) and [rules](https://cake-contrib.github.io/CakeContrib.Guidelines/rules) are documented at <https://cake-contrib.github.io/CakeContrib.Guidelines/>

## Discussion

If you have questions, search for an existing one, or create a new discussion on the Cake GitHub repository, using the `extension-q-a` category.

[![Join in the discussion on the Cake repository](https://img.shields.io/badge/GitHub-Discussions-green?logo=github)](https://github.com/cake-build/cake/discussions)

## Maintainer

[Nils Andresen @nils-a][maintainer]
Expand All @@ -62,7 +69,20 @@ This project follows the [all-contributors][] specification. Contributions of an
Thanks goes to these wonderful people ([emoji key][emoji-key]):

<!-- ALL-CONTRIBUTORS-LIST:START - Do not remove or modify this section -->
<!-- prettier-ignore -->
<!-- prettier-ignore-start -->
<!-- markdownlint-disable -->
<table>
<tr>
<td align="center"><a href="https://github.com/AdmiringWorm"><img src="https://avatars.githubusercontent.com/u/1474648?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Kim J. Nordmo</b></sub></a><br /><a href="#question-AdmiringWorm" title="Answering Questions">💬</a> <a href="#ideas-AdmiringWorm" title="Ideas, Planning, & Feedback">🤔</a></td>
<td align="center"><a href="https://github.com/Jericho"><img src="https://avatars.githubusercontent.com/u/112710?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Jericho</b></sub></a><br /><a href="https://github.com/cake-contrib/CakeContrib.Guidelines/issues?q=author%3AJericho" title="Bug reports">🐛</a> <a href="#ideas-Jericho" title="Ideas, Planning, & Feedback">🤔</a></td>
<td align="center"><a href="https://github.com/nils-a"><img src="https://avatars.githubusercontent.com/u/349188?v=4?s=100" width="100px;" alt=""/><br /><sub><b>Nils Andresen</b></sub></a><br /><a href="https://github.com/cake-contrib/CakeContrib.Guidelines/commits?author=nils-a" title="Code">💻</a> <a href="#maintenance-nils-a" title="Maintenance">🚧</a></td>
<td align="center"><a href="https://augustoproiete.net"><img src="https://avatars.githubusercontent.com/u/177608?v=4?s=100" width="100px;" alt=""/><br /><sub><b>C. Augusto Proiete</b></sub></a><br /><a href="#ideas-augustoproiete" title="Ideas, Planning, & Feedback">🤔</a> <a href="https://github.com/cake-contrib/CakeContrib.Guidelines/pulls?q=is%3Apr+reviewed-by%3Aaugustoproiete" title="Reviewed Pull Requests">👀</a></td>
</tr>
</table>

<!-- markdownlint-restore -->
<!-- prettier-ignore-end -->

<!-- ALL-CONTRIBUTORS-LIST:END -->

## License
Expand Down
Empty file modified build.sh
100644 → 100755
Empty file.
47 changes: 11 additions & 36 deletions docs/input/guidelines/CakeContribIcon.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
---
Order: 1
Title: CakeContrib-Icon
---

Expand All @@ -11,9 +10,8 @@ Title: CakeContrib-Icon
- [Related rules](#related-rules)
- [Usage](#usage)
- [Settings](#settings)
- [Icon-Location](#icon-location)
- [Icon include in project](#icon-include-in-project)
- [migrating from an existing project](#migrating-from-an-existing-project)
- [Migrating from an existing project](#migrating-from-an-existing-project)

<!-- END doctoc generated TOC please keep comment here to allow auto update -->

Expand All @@ -34,45 +32,22 @@ Title: CakeContrib-Icon
Using this package automatically enables this guideline.

With no special settings at all (i.e. "The Standard"):
* the current cake-contrib icon will be copied as "icon.png" in the project-directory
* the icon will be included in the project
* if no `PackageIcon` property is specified, a default will be assigned.
* if no icon (matching the `PackageIcon` property) is referenced in the project, a default will be referenced.
* if the referenced icon is not binary equal to the default icon, it will be updated.
* if no `PackageIconUrl` property is specified, a default will be assigned.

## Settings

### Icon-Location
The default location of the icon is `icon.png`, next to the csproj (i.e. `$(MSBuildProjectDirectory)/icon.png`).

Setting `CakeContribGuidelinesIconDestinationLocation` makes it possible to override the default location of the Icon. For example setting

```xml
<PropertyGroup>
<IconDestinationLocation>../logo.png</IconDestinationLocation>
</PropertyGroup>
```

in the csproj will place the icon as `logo.png` one folder up (relative to the current project).

### Icon include in project
The icon will be automatically included in the project, unless `CakeContribGuidelinesIconOmitImport` was defined.

To to use a "custom" import the following could be used:
<?! Include "../settings/fragments/IconOmitImport.md" /?>

```xml
<PropertyGroup>
<CakeContribGuidelinesIconOmitImport>1</CakeContribGuidelinesIconOmitImport>
</PropertyGroup>
<ItemGroup>
<None Include="$(CakeContribGuidelinesIconDestinationLocation)">
<Pack>True</Pack>
<PackagePath></PackagePath>
</None>
</ItemGroup>
```
## Migrating from an existing project

### migrating from an existing project
No steps are needed anymore. Existing settings will be detected and honored.

Optionally:
* remove the existing icon
* remove the `Include` of the icon from the project-file
* add a reference to CakeContrib.Guidelines
* build the project
* set `PackageIcon` to `icon.png`
* remove the `PackageIcon` from the project-file
* remove the `PackageIconUrl` from the project-file
11 changes: 1 addition & 10 deletions docs/input/guidelines/PrivateAssets.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
---
Order: 2
Title: PrivateAssets in references
---

Expand Down Expand Up @@ -32,12 +31,4 @@ Using this package automatically enables this guideline.

### Opt-Out

It it possible to opt-out of the check for `PrivateAssets` using the following setting:

(*Keep in mind, though that it is not recommended to opt-out of this feature*)

```xml
<PropertyGroup>
<CakeContribGuidelinesCakeReferenceOmitPrivateCheck>1</CakeContribGuidelinesCakeReferenceOmitPrivateCheck>
</PropertyGroup>
```
<?! Include "../settings/fragments/OmitPrivateCheck.md" /?>
36 changes: 36 additions & 0 deletions docs/input/guidelines/RecommendedCakeVersion.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
---
Title: Recommended Cake Version
---

<!-- START doctoc generated TOC please keep comment here to allow auto update -->
<!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE -->
## Table of Contents

- [Goals](#goals)
- [Related rules](#related-rules)
- [Usage](#usage)
- [Settings](#settings)
- [Opt-Out](#opt-out)

<!-- END doctoc generated TOC please keep comment here to allow auto update -->

## Goals

For addins and modules it is recommended to reference the lowest version of Cake with API compatibility to the latest version.
This is currently version 1.0.0.

## Related rules

* [CCG0009](../rules/ccg0009)

This rule is only applied for [project types](../settings#projecttype) `addin` and `module`.

## Usage

Using this package automatically enables this guideline.

## Settings

### Opt-Out

<?! Include "../settings/fragments/OmitRecommendedCakeVersion.md" /?>
Loading

0 comments on commit d3d305c

Please sign in to comment.