mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Update doc
This commit is contained in:
parent
2e7c024f45
commit
5a540f646c
10 changed files with 249 additions and 94 deletions
151
.github/workflows/build-MCC-only.yml
vendored
Normal file
151
.github/workflows/build-MCC-only.yml
vendored
Normal file
|
|
@ -0,0 +1,151 @@
|
|||
name: Build MCC
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
env:
|
||||
PROJECT: "MinecraftClient"
|
||||
target-version: "net6.0"
|
||||
compile-flags: "--self-contained=true -c Release -p:UseAppHost=true -p:IncludeNativeLibrariesForSelfExtract=true -p:DebugType=None"
|
||||
|
||||
jobs:
|
||||
Build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: 'true'
|
||||
|
||||
- name: Sync translations from crowdin
|
||||
uses: crowdin/github-action@1.5.0
|
||||
with:
|
||||
upload_translations: true
|
||||
download_translations: true
|
||||
|
||||
localization_branch_name: l10n_master
|
||||
create_pull_request: false
|
||||
|
||||
base_path: ${{ github.workspace }}
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
|
||||
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_TOKEN }}
|
||||
|
||||
- name: Setup Project Path
|
||||
run: |
|
||||
echo project-path=${{ github.workspace }}/${{ env.PROJECT }} >> $GITHUB_ENV
|
||||
|
||||
- name: Setup Output Paths
|
||||
run: |
|
||||
echo win-x64-out-path=${{ env.project-path }}/bin/Release/${{ env.target-version }}/win-x64/publish/ >> $GITHUB_ENV
|
||||
echo win-x86-out-path=${{ env.project-path }}/bin/Release/${{ env.target-version }}/win-x86/publish/ >> $GITHUB_ENV
|
||||
echo linux-out-path=${{ env.project-path }}/bin/Release/${{ env.target-version }}/linux-x64/publish/ >> $GITHUB_ENV
|
||||
echo osx-out-path=${{ env.project-path }}/bin/Release/${{ env.target-version }}/osx-x64/publish/ >> $GITHUB_ENV
|
||||
echo linux-arm64-out-path=${{ env.project-path }}/bin/Release/${{ env.target-version }}/linux-arm64/publish/ >> $GITHUB_ENV
|
||||
|
||||
- name: Setup .NET SDK
|
||||
uses: actions/setup-dotnet@v2.1.0
|
||||
|
||||
- name: Get Version DateTime
|
||||
id: date-version
|
||||
uses: nanzm/get-time-action@v1.1
|
||||
with:
|
||||
timeZone: 0
|
||||
format: 'YYYY-MM-DD'
|
||||
|
||||
- name: VersionInfo
|
||||
run: |
|
||||
COMMIT=$(echo ${{ github.sha }} | cut -c 1-7)
|
||||
echo '' >> ${{ env.project-path }}/Properties/AssemblyInfo.cs
|
||||
echo "[assembly: AssemblyConfiguration(\"GitHub build ${{ github.run_number }}, built on ${{ steps.date-version.outputs.time }} from commit $COMMIT\")]" >> ${{ env.project-path }}/Properties/AssemblyInfo.cs
|
||||
|
||||
- name: Build for Windows x64
|
||||
run: dotnet publish ${{ env.project-path }}.sln -f ${{ env.target-version }} -r win-x64 ${{ env.compile-flags }}
|
||||
|
||||
- name: Zip Windows x64 Build
|
||||
run: zip -qq -r windows-x64.zip *
|
||||
working-directory: ${{ env.win-x64-out-path }}
|
||||
|
||||
- name: Build for Windows x86
|
||||
run: dotnet publish ${{ env.project-path }}.sln -f ${{ env.target-version }} -r win-x86 ${{ env.compile-flags }}
|
||||
|
||||
- name: Zip Windows x86 Build
|
||||
run: zip -qq -r windows-x86.zip *
|
||||
working-directory: ${{ env.win-x86-out-path }}
|
||||
|
||||
- name: Build for Linux
|
||||
run: dotnet publish ${{ env.project-path }}.sln -f ${{ env.target-version }} -r linux-x64 ${{ env.compile-flags }}
|
||||
|
||||
- name: Zip Linux Build
|
||||
run: zip -qq -r linux.zip *
|
||||
working-directory: ${{ env.linux-out-path }}
|
||||
|
||||
- name: Build for ARM64 Linux
|
||||
run: dotnet publish ${{ env.project-path }}.sln -f ${{ env.target-version }} -r linux-arm64 ${{ env.compile-flags }}
|
||||
|
||||
- name: Zip ARM64 Linux Build
|
||||
run: zip -qq -r linux-arm64.zip *
|
||||
working-directory: ${{ env.linux-arm64-out-path }}
|
||||
|
||||
- name: Build for OSX
|
||||
run: dotnet publish ${{ env.project-path }}.sln -f ${{ env.target-version }} -r osx-x64 ${{ env.compile-flags }}
|
||||
|
||||
- name: Zip OSX Build
|
||||
run: zip -qq -r osx.zip *
|
||||
working-directory: ${{ env.osx-out-path }}
|
||||
|
||||
- name: Get Release DateTime
|
||||
id: date-release
|
||||
uses: nanzm/get-time-action@v1.1
|
||||
with:
|
||||
timeZone: 0
|
||||
format: 'YYYYMMDD'
|
||||
|
||||
- name: Windows x64 Release
|
||||
uses: tix-factory/release-manager@v1
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
mode: uploadReleaseAsset
|
||||
filePath: ${{ env.win-x64-out-path }}windows-x64.zip
|
||||
assetName: ${{ env.PROJECT }}-windows-x64.zip
|
||||
tag: ${{ format('{0}-{1}', steps.date-release.outputs.time, github.run_number) }}
|
||||
|
||||
- name: Windows x86 Release
|
||||
uses: tix-factory/release-manager@v1
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
mode: uploadReleaseAsset
|
||||
filePath: ${{ env.win-x86-out-path }}windows-x86.zip
|
||||
assetName: ${{ env.PROJECT }}-windows-x86.zip
|
||||
tag: ${{ format('{0}-{1}', steps.date-release.outputs.time, github.run_number) }}
|
||||
|
||||
- name: Linux Release
|
||||
uses: tix-factory/release-manager@v1
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
mode: uploadReleaseAsset
|
||||
filePath: ${{ env.linux-out-path }}linux.zip
|
||||
assetName: ${{ env.PROJECT }}-linux.zip
|
||||
tag: ${{ format('{0}-{1}', steps.date-release.outputs.time, github.run_number) }}
|
||||
|
||||
- name: Linux ARM64 Release
|
||||
uses: tix-factory/release-manager@v1
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
mode: uploadReleaseAsset
|
||||
filePath: ${{ env.linux-arm64-out-path }}linux-arm64.zip
|
||||
assetName: ${{ env.PROJECT }}-linux-arm64.zip
|
||||
tag: ${{ format('{0}-{1}', steps.date-release.outputs.time, github.run_number) }}
|
||||
|
||||
- name: OSX Release
|
||||
uses: tix-factory/release-manager@v1
|
||||
with:
|
||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||
mode: uploadReleaseAsset
|
||||
filePath: ${{ env.osx-out-path }}osx.zip
|
||||
assetName: ${{ env.PROJECT }}-osx.zip
|
||||
tag: ${{ format('{0}-{1}', steps.date-release.outputs.time, github.run_number) }}
|
||||
2
.github/workflows/build-and-release.yml
vendored
2
.github/workflows/build-and-release.yml
vendored
|
|
@ -1,4 +1,4 @@
|
|||
name: Build
|
||||
name: Build MCC and Documents
|
||||
|
||||
on:
|
||||
push:
|
||||
|
|
|
|||
42
.github/workflows/deploy-doc-only.yml
vendored
Normal file
42
.github/workflows/deploy-doc-only.yml
vendored
Normal file
|
|
@ -0,0 +1,42 @@
|
|||
name: Build Documents
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
Build:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: 'true'
|
||||
|
||||
- name: Sync translations from crowdin
|
||||
uses: crowdin/github-action@1.5.0
|
||||
with:
|
||||
upload_translations: true
|
||||
download_translations: true
|
||||
|
||||
localization_branch_name: l10n_master
|
||||
create_pull_request: false
|
||||
|
||||
base_path: ${{ github.workspace }}
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
|
||||
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_TOKEN }}
|
||||
|
||||
- name: Deploy Documentation Site
|
||||
uses: jenkey2011/vuepress-deploy@master
|
||||
env:
|
||||
ACCESS_TOKEN: ${{ secrets.GH_PAGES_TOKEN }}
|
||||
TARGET_REPO: MCCTeam/MCCTeam.github.io
|
||||
TARGET_BRANCH: master
|
||||
BUILD_SCRIPT: yarn --cwd ./docs/ && yarn --cwd ./docs/ docs:build
|
||||
BUILD_DIR: docs/.vuepress/dist
|
||||
COMMIT_MESSAGE: Build from ${{ github.sha }}
|
||||
CNAME: https://mccteam.github.io
|
||||
31
.github/workflows/sync-translations-only.yml
vendored
Normal file
31
.github/workflows/sync-translations-only.yml
vendored
Normal file
|
|
@ -0,0 +1,31 @@
|
|||
name: Sync Translations
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
Sync:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
submodules: 'true'
|
||||
|
||||
- name: Sync translations from crowdin
|
||||
uses: crowdin/github-action@1.5.0
|
||||
with:
|
||||
upload_translations: true
|
||||
download_translations: true
|
||||
|
||||
localization_branch_name: l10n_master
|
||||
create_pull_request: false
|
||||
|
||||
base_path: ${{ github.workspace }}
|
||||
env:
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
CROWDIN_PROJECT_ID: ${{ secrets.CROWDIN_PROJECT_ID }}
|
||||
CROWDIN_PERSONAL_TOKEN: ${{ secrets.CROWDIN_TOKEN }}
|
||||
Loading…
Add table
Add a link
Reference in a new issue