Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastian-heinz committed Nov 24, 2019
0 parents commit 4c58741
Show file tree
Hide file tree
Showing 112 changed files with 8,662 additions and 0 deletions.
15 changes: 15 additions & 0 deletions .editorconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
###############################
# Core EditorConfig Options #
###############################

root = true

# All files
[*]
indent_style = space

# Code files
[*.cs]
indent_size = 4
insert_final_newline = true
charset = utf-8
18 changes: 18 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# Set the default behavior, in case people don't have core.autocrlf set.
#* text=auto

# Explicitly declare text files you want to always be normalized and converted
# to native line endings on checkout.
#*.c text
#*.h text

# Declare files that will always have CRLF line endings on checkout.
#*.sln text eol=crlf

# Denote all files that are truly binary and should not be modified.
*.DAT binary
*.ico binary
*.jpg binary
*.exe binary
*.dll binary
*.pfx binary
27 changes: 27 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
name: Bug report
about: Create a report to help us improve
title: ''
labels: bug
assignees: ''

---

**Describe the bug**
A clear and concise description of what the bug is.

**To Reproduce**
Steps to reproduce the behavior:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error

**Expected behavior**
A clear and concise description of what you expected to happen.

**Screenshots**
If applicable, add screenshots to help explain your problem.

**Additional context**
Add any other context about the problem here.
20 changes: 20 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
---
name: Feature request
about: Suggest an idea for this project
title: ''
labels: feature
assignees: ''

---

**Please describe the idea.**
A clear and concise description of the features functionality is. Ex. I'd like to have a command that [...]

**Describe the solution you'd like**
A clear and concise description of what you want to happen.

**Describe alternatives you've considered**
A clear and concise description of any alternative solutions or features you've considered.

**Additional context**
Add any other context or screenshots about the feature request here.
13 changes: 13 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Build
on: [pull_request]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.0.100
- name: Build Project
run: dotnet build --configuration Release
85 changes: 85 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
name: Create Release
on:
push:
branches:
- master
jobs:
build:
runs-on: ubuntu-latest
steps:

- name: Checkout
uses: actions/checkout@v1

- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.0.100

- name: Build Release
id: build_release
run: |
MHF_VERSION_FILE=${{ github.workspace }}/mhf.version
MHF_VERSION=$(<"$MHF_VERSION_FILE")
echo ::set-env name=MHF_VERSION::$MHF_VERSION
echo ::set-env name=MHF_VERSION_E::$(echo ${GITHUB_SHA} | cut -c1-8)
mkdir ./release
for MHF_RUNTIME in win-x86 win-x64 linux-x64 osx-x64; do
# Server
dotnet publish Mhf.Cli/Mhf.Cli.csproj /p:Version=$MHF_VERSION /p:FromMSBuild=true --runtime $MHF_RUNTIME --configuration Release --output ./publish/$MHF_RUNTIME-$MHF_VERSION/Server
# ReleaseFiles
cp -r ./ReleaseFiles/. ./publish/$MHF_RUNTIME-$MHF_VERSION/
# Pack
tar cjf ./release/$MHF_RUNTIME-$MHF_VERSION.tar.gz ./publish/$MHF_RUNTIME-$MHF_VERSION
done
- name: Create Release
id: create_release
uses: actions/create-release@v1.0.0
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: release-${{ env.MHF_VERSION }}-${{ env.MHF_VERSION_E }}
release_name: Release ${{ env.MHF_VERSION }}-${{ env.MHF_VERSION_E }}
draft: false
prerelease: false

- name: Upload win-x86 Release Asset
uses: actions/upload-release-asset@v1.0.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./release/win-x86-${{ env.MHF_VERSION }}.tar.gz
asset_name: win-x86-${{ env.MHF_VERSION }}-${{ env.MHF_VERSION_E }}.tar.gz
asset_content_type: application/gzip

- name: Upload win-x64 Release Asset
uses: actions/upload-release-asset@v1.0.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./release/win-x64-${{ env.MHF_VERSION }}.tar.gz
asset_name: win-x64-${{ env.MHF_VERSION }}-${{ env.MHF_VERSION_E }}.tar.gz
asset_content_type: application/gzip

- name: Upload linux-x64 Release Asset
uses: actions/upload-release-asset@v1.0.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./release/linux-x64-${{ env.MHF_VERSION }}.tar.gz
asset_name: linux-x64-${{ env.MHF_VERSION }}-${{ env.MHF_VERSION_E }}.tar.gz
asset_content_type: application/gzip

- name: Upload osx-x64 Release Asset
uses: actions/upload-release-asset@v1.0.1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./release/osx-x64-${{ env.MHF_VERSION }}.tar.gz
asset_name: osx-x64-${{ env.MHF_VERSION }}-${{ env.MHF_VERSION_E }}.tar.gz
asset_content_type: application/gzip
42 changes: 42 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
## Folders specific
/publish/
/release/
/packages/

## Folders anywhere
.idea/
.vs/

## Files anywhere
*.DS_Store

## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.

# User-specific files
*.suo
*.user
*.userosscache
*.sln.docstates

# Build results
[Dd]ebug/
[Dd]ebugPublic/
[Rr]elease/
[Rr]eleases/
x64/
x86/
build/
bld/
[Bb]in/
[Oo]bj/

# Visual Studio profiler
*.psess
*.vsp
*.vspx

# ReSharper is a .NET coding add-in
_ReSharper*/
*.[Rr]e[Ss]harper
*.DotSettings.user
Loading

0 comments on commit 4c58741

Please sign in to comment.