Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create dotnet.yml #1

Merged
merged 5 commits into from
Jun 24, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
45 changes: 45 additions & 0 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
# This workflow will build a .NET project
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-net

name: .NET

on:
push:
branches: [ "main" ]

jobs:
build:

runs-on: ubuntu-latest
environment: Package
steps:
- uses: actions/checkout@v4
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: 8.0.x
- name: Restore dependencies
run: dotnet restore
- name: Build
run: dotnet build --no-restore
- name: Change CD
run: cd OneDriveRipper
- name: Prepare RPM packaging
run: dotnet tool install --global dotnet-rpm
- name: Prepare DEB packaging
run: dotnet tool install --global dotnet-deb
- name: Install RPM packaging tool
run: dotnet rpm install
- name: Install DEB packagin tool
run: dotnet deb install
- name: Create RPM package
run: cd OneDriveRipper && dotnet rpm -c Release -o dist-release
- name: Create DEB package
run: cd OneDriveRipper && dotnet deb -c Release -o dist-release
- name: Publish packages
uses: TykTechnologies/packagecloud-action@v1
env:
PACKAGECLOUD_TOKEN: ${{ secrets.PACKAGECLOUD_TOKEN }}
with:
repo: 'thonkdifferent/onedriveripper'
dir: './OneDriveRipper/dist-release/'