Skip to content

Commit

Permalink
Initial Template Commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ElanHasson committed Aug 7, 2022
1 parent 3b58034 commit 1545970
Show file tree
Hide file tree
Showing 36 changed files with 1,686 additions and 3 deletions.
458 changes: 458 additions & 0 deletions .editorconfig

Large diffs are not rendered by default.

43 changes: 43 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
###############################
# Git Line Endings #
###############################

# Set default behavior to automatically normalize line endings.
* text=auto

# Force batch scripts to always use CRLF line endings so that if a repo is accessed
# in Windows via a file share from Linux, the scripts will work.
*.{cmd,[cC][mM][dD]} text eol=crlf
*.{bat,[bB][aA][tT]} text eol=crlf

# Force bash scripts to always use LF line endings so that if a repo is accessed
# in Unix via a file share from Windows, the scripts will work.
*.sh text eol=lf

###############################
# Git Large File System (LFS) #
###############################

# Archives
*.7z filter=lfs diff=lfs merge=lfs -text
*.br filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.tar filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text

# Documents
*.pdf filter=lfs diff=lfs merge=lfs -text

# Images
*.gif filter=lfs diff=lfs merge=lfs -text
*.ico filter=lfs diff=lfs merge=lfs -text
*.jpg filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.psd filter=lfs diff=lfs merge=lfs -text
*.webp filter=lfs diff=lfs merge=lfs -text

# Fonts
*.woff2 filter=lfs diff=lfs merge=lfs -text

# Other
*.exe filter=lfs diff=lfs merge=lfs -text
76 changes: 76 additions & 0 deletions .github/CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
# Contributor Covenant Code of Conduct

## Our Pledge

In the interest of fostering an open and welcoming environment, we as
contributors and maintainers pledge to making participation in our project and
our community a harassment-free experience for everyone, regardless of age, body
size, disability, ethnicity, sex characteristics, gender identity and expression,
level of experience, education, socio-economic status, nationality, personal
appearance, race, religion, or sexual identity and orientation.

## Our Standards

Examples of behaviour that contributes to creating a positive environment
include:

* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members

Examples of unacceptable behaviour by participants include:

* The use of sexualized language or imagery and unwelcome sexual attention or
advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic
address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a
professional setting

## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable
behaviour and are expected to take appropriate and fair corrective action in
response to any instances of unacceptable behaviour.

Project maintainers have the right and responsibility to remove, edit, or
reject comments, commits, code, wiki edits, issues, and other contributions
that are not aligned to this Code of Conduct, or to ban temporarily or
permanently any contributor for other behaviours that they deem inappropriate,
threatening, offensive, or harmful.

## Scope

This Code of Conduct applies both within project spaces and in public spaces
when an individual is representing the project or its community. Examples of
representing a project or community include using an official project e-mail
address, posting via an official social media account, or acting as an appointed
representative at an online or offline event. Representation of a project may be
further defined and clarified by project maintainers.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behaviour may be
reported by contacting [@ElanHasson]. All
complaints will be reviewed and investigated and will result in a response that
is deemed necessary and appropriate to the circumstances. The project team is
obligated to maintain confidentiality with regard to the reporter of an incident.
Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good
faith may face temporary or permanent repercussions as determined by other
members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct.html

[homepage]: https://www.contributor-covenant.org

For answers to common questions about this code of conduct, see
https://www.contributor-covenant.org/faq
16 changes: 16 additions & 0 deletions .github/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# All contributions, however small are valued!

# Steps to contribute

If you want to make a small change, go ahead and raise a pull request, otherwise follow these steps:

1. View the [Issues](https://github.com/ElanHasson/Orleans.StorageProviderInterceptors/issues) page to see a To-Do list of things to be implemented.
2. Raise an issue or comment on an existing issue with what you want to contribute if one does not already exist.
3. When you get the go ahead, follow the coding guidelines and raise a pull request.
4. Include a link to the issue in your pull request.

# Coding Guidelines

- Projects use StyleCop and .editorconfig to produce style warnings. Please fix all warnings in any code you submit.
- Write unit tests for any code written.

13 changes: 13 additions & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# These are supported funding model platforms

github: [ElanHasson]# Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
patreon: # Replace with a single Patreon username
open_collective: # Replace with a single Open Collective username
ko_fi: # Replace with a single Ko-fi username
tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
liberapay: # Replace with a single Liberapay username
issuehunt: # Replace with a single IssueHunt username
otechie: # Replace with a single Otechie username
lfx_crowdfunding: # Replace with a single LFX Crowdfunding project-name e.g., cloud-foundry
custom: # Replace with up to 4 custom sponsorship URLs e.g., ['link1', 'link2']
30 changes: 30 additions & 0 deletions .github/ISSUE_TEMPLATE/BUG_REPORT.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: "Bug Report"
description: "Create a report to help us improve"
labels: [bug]
body:
- type: textarea
id: describe-the-bug
attributes:
label: "Describe the bug"
description: "A clear and concise description of what the bug is."
validations:
required: true
- type: textarea
id: steps-to-reproduce
attributes:
label: "Steps to reproduce"
description: "A link to some code to reproduce the bug can speed up a fix. Alternatively, show steps to reproduce the behaviour."
placeholder: |
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error
validations:
required: true
- type: textarea
id: expected-behaviour
attributes:
label: "Expected behaviour"
description: "A clear and concise description of what you expected to happen."
validations:
required: true
11 changes: 11 additions & 0 deletions .github/ISSUE_TEMPLATE/FEATURE_REQUEST.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: "Feature Request"
description: "Suggest an idea for this project"
labels: [enhancement]
body:
- type: textarea
id: describe-the-bug
attributes:
label: "Describe the feature"
description: "A clear and concise description of what the feature is."
validations:
required: true
6 changes: 6 additions & 0 deletions .github/PULL_REQUEST_TEMPLATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
<!--
Thank you good citizen for your hard work!
Please read the contributing guide before raising a pull request.
https://github.com/ElanHasson/Orleans.StorageProviderInterceptors/blob/main/.github/CONTRIBUTING.md
-->
9 changes: 9 additions & 0 deletions .github/SECURITY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Security Policy

## Supported Versions

This project supports only the latest version with security updates. However, we'll do our best to help and answer questions about older versions.

## Reporting a Vulnerability

Contact [@ElanHasson] to report a security vulnerability. You will be thanked!
19 changes: 19 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
# Please see the documentation for all configuration options:
# https://docs.github.com/en/code-security/supply-chain-security/configuration-options-for-dependency-updates

version: 2
updates:
- package-ecosystem: "nuget"
directory: "/"
labels:
- "dependencies"
open-pull-requests-limit: 10
schedule:
interval: "daily"
- package-ecosystem: "github-actions"
directory: "/"
labels:
- "dependencies"
open-pull-requests-limit: 10
schedule:
interval: "daily"
52 changes: 52 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# release-drafter automatically creates a draft release for you each time you complete a PR in the main branch.
# It uses GitHub labels to categorize changes (See categories) and draft the release.
# release-drafter also generates a version for your release based on GitHub labels. You can add a label of 'major',
# 'minor' or 'patch' to determine which number in the version to increment.
# You may need to add these labels yourself.
# See https://github.com/release-drafter/release-drafter
name-template: "$RESOLVED_VERSION"
tag-template: "$RESOLVED_VERSION"
change-template: "- $TITLE by @$AUTHOR (#$NUMBER)"
no-changes-template: "- No changes"
categories:
- title: "📚 Documentation"
labels:
- "documentation"
- title: "🚀 New Features"
labels:
- "enhancement"
- title: "🐛 Bug Fixes"
labels:
- "bug"
- title: "🧰 Maintenance"
labels:
- "maintenance"
version-resolver:
major:
labels:
- "major"
minor:
labels:
- "minor"
patch:
labels:
- "patch"
default: patch
template: |
$CHANGES
## 👨🏼‍💻 Contributors
$CONTRIBUTORS
autolabeler:
- label: "documentation"
files:
- "**/*.md"
- label: "enhancement"
files:
- "Source/**/*"
- label: "maintenance"
files:
- ".github/**/*"
- "Images/**/*"
- "Tests/**/*"
96 changes: 96 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
name: Build

on:
push:
branches:
- main
pull_request:
release:
types:
- published
workflow_dispatch:

env:
# Disable the .NET logo in the console output.
DOTNET_NOLOGO: true
# Disable the .NET first time experience to skip caching NuGet packages and speed up the build.
DOTNET_SKIP_FIRST_TIME_EXPERIENCE: true
# Disable sending .NET CLI telemetry to Microsoft.
DOTNET_CLI_TELEMETRY_OPTOUT: true
# Set the build number in MinVer.
MINVERBUILDMETADATA: build.${{github.run_number}}

jobs:
build:
name: Build-${{matrix.os}}
runs-on: ${{matrix.os}}
strategy:
matrix:
os: [ubuntu-latest]
steps:
- name: "Checkout"
uses: actions/checkout@v3.0.2
with:
lfs: true
fetch-depth: 0
- name: "Install .NET Core SDK"
uses: actions/setup-dotnet@v2.1.0
- name: "Dotnet Tool Restore"
run: dotnet tool restore
shell: pwsh
- name: "Dotnet Cake Build"
run: dotnet cake --target=Build
shell: pwsh
- name: "Dotnet Cake Test"
run: dotnet cake --target=Test
shell: pwsh
- name: "Dotnet Cake Pack"
run: dotnet cake --target=Pack
shell: pwsh
- name: "Publish Artifacts"
uses: actions/upload-artifact@v3.1.0
with:
name: ${{matrix.os}}
path: "./Artifacts"

push-github-packages:
name: "Push GitHub Packages"
needs: build
if: github.ref == 'refs/heads/main' || github.event_name == 'release'
environment:
name: "GitHub Packages"
url: https://github.com/ElanHasson/Orleans.StorageProviderInterceptors/packages
permissions:
packages: write
runs-on: windows-latest
steps:
- name: "Download Artifact"
uses: actions/download-artifact@v3.0.0
with:
name: "windows-latest"
- name: "Dotnet NuGet Add Source"
run: dotnet nuget add source https://nuget.pkg.github.com/ElanHasson/index.json --name GitHub --username ElanHasson --password ${{secrets.GH_TOKEN}}
shell: pwsh
- name: "Dotnet NuGet Push"
run: dotnet nuget push .\*.nupkg --api-key ${{ github.token }} --source GitHub --skip-duplicate
shell: pwsh

push-nuget:
name: "Push NuGet Packages"
needs: build
if: github.event_name == 'release'
environment:
name: "NuGet"
url: https://www.nuget.org/packages/Orleans.StorageProviderInterceptors
runs-on: windows-latest
steps:
- name: "Download Artifact"
uses: actions/download-artifact@v3.0.0
with:
name: "windows-latest"
- name: "Dotnet NuGet Push"
run: |
Get-ChildItem .\ -Filter *.nupkg |
Where-Object { !$_.Name.Contains('preview') } |
ForEach-Object { dotnet nuget push $_ --source https://api.nuget.org/v3/index.json --skip-duplicate --api-key ${{secrets.NUGET_API_KEY}} }
shell: pwsh
Loading

0 comments on commit 1545970

Please sign in to comment.