mirror of
https://github.com/daffyyyy/CS2-SimpleAdmin.git
synced 2026-02-24 12:19:17 +00:00
Merge branch 'main' of https://github.com/daffyyyy/CS2-SimpleAdmin
This commit is contained in:
67
.github/workflows/build.yml
vendored
Normal file
67
.github/workflows/build.yml
vendored
Normal file
@@ -0,0 +1,67 @@
|
|||||||
|
name: Build
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches: [ "main" ]
|
||||||
|
pull_request:
|
||||||
|
branches: [ "main" ]
|
||||||
|
|
||||||
|
env:
|
||||||
|
BUILD_NUMBER: ${{ github.run_number }}
|
||||||
|
PROJECT_PATH: "CS2-SimpleAdmin.csproj"
|
||||||
|
PROJECT_NAME: "CS2-SimpleAdmin"
|
||||||
|
OUTPUT_PATH: "./CS2-SimpleAdmin"
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build:
|
||||||
|
permissions: write-all
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: Setup .NET
|
||||||
|
uses: actions/setup-dotnet@v3
|
||||||
|
with:
|
||||||
|
dotnet-version: 7.0.x
|
||||||
|
- name: Restore
|
||||||
|
run: dotnet restore
|
||||||
|
- name: Build
|
||||||
|
run: dotnet build ${{ env.PROJECT_PATH }} -c CS2-SimpleAdmin -o ${{ env.OUTPUT_PATH }}
|
||||||
|
|
||||||
|
publish:
|
||||||
|
if: github.event_name == 'push'
|
||||||
|
permissions: write-all
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
needs: build
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- name: Setup .NET
|
||||||
|
uses: actions/setup-dotnet@v3
|
||||||
|
with:
|
||||||
|
dotnet-version: 7.0.x
|
||||||
|
- name: Restore
|
||||||
|
run: dotnet restore
|
||||||
|
- name: Build
|
||||||
|
run: dotnet build ${{ env.PROJECT_PATH }} -c CS2-SimpleAdmin -o ${{ env.OUTPUT_PATH }}
|
||||||
|
- name: Clean files
|
||||||
|
run: |
|
||||||
|
rm -f \
|
||||||
|
${{ env.OUTPUT_PATH }}/CounterStrikeSharp.API.dll \
|
||||||
|
${{ env.OUTPUT_PATH }}/McMaster.NETCore.Plugins.dll \
|
||||||
|
${{ env.OUTPUT_PATH }}/Microsoft.DotNet.PlatformAbstractions.dll \
|
||||||
|
${{ env.OUTPUT_PATH }}/Microsoft.Extensions.DependencyModel.dll \
|
||||||
|
- name: Zip
|
||||||
|
uses: thedoctor0/zip-release@0.7.5
|
||||||
|
with:
|
||||||
|
type: 'zip'
|
||||||
|
filename: '${{ env.PROJECT_NAME }}.zip'
|
||||||
|
path: ${{ env.OUTPUT_PATH }}
|
||||||
|
- name: CS2-SimpleAdmin
|
||||||
|
uses: ncipollo/release-action@v1.12.0
|
||||||
|
with:
|
||||||
|
artifacts: "${{ env.PROJECT_NAME }}.zip"
|
||||||
|
name: "Build ${{ env.BUILD_NUMBER }}"
|
||||||
|
tag: "build-${{ env.BUILD_NUMBER }}"
|
||||||
|
body: |
|
||||||
|
Place the plugin in game/csgo/addons/counterstrikesharp/plugins/CS2-SimpleAdmin
|
||||||
|
After first launch, u need to configure plugin in addons/counterstrikesharp/configs/plugins/CS2-SimpleAdmin/CS2-SimpleAdmin.json
|
||||||
@@ -41,3 +41,5 @@ After first launch, u need to configure plugin in addons/counterstrikesharp/con
|
|||||||
public static char LightRed = '\x0F';
|
public static char LightRed = '\x0F';
|
||||||
```
|
```
|
||||||
Use color name for e.g. {LightRed}
|
Use color name for e.g. {LightRed}
|
||||||
|
|
||||||
|
Credits for https://github.com/Hackmastr/css-basic-admin/
|
||||||
|
|||||||
Reference in New Issue
Block a user