-
Notifications
You must be signed in to change notification settings - Fork 115
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[PW-6181] Add workflow for nuget package (#733)
* Add workflow for nuget package * Changed workflow to custom dotnet packaging * final changes * Add workflow to create release notes * cleaned up the yml * Merge develop and remove release workflow * remove random abstractOpenApiSchema file * Update .github/workflows/publish.yml --------- Co-authored-by: Alexandros Moraitis <alexandros.moraitis@adyen.com>
- Loading branch information
1 parent
6edb0cb
commit 67316a5
Showing
3 changed files
with
55 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
changelog: | ||
categories: | ||
- title: Breaking Changes 🛠 | ||
labels: | ||
- Breaking change | ||
- title: New Features 💎 | ||
labels: | ||
- Feature | ||
- title: Fixes ⛑️ | ||
labels: | ||
- Fix | ||
- title: Other Changes 🖇️ | ||
labels: | ||
- "*" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: publish to nuget | ||
on: | ||
push: | ||
branches: | ||
- main #push to main | ||
jobs: | ||
# publish the nuget package | ||
publish: | ||
name: build, pack & publish | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
# Sets up .NET | ||
- name: Setup .NET | ||
uses: actions/setup-dotnet@v3 | ||
with: | ||
dotnet-version: | | ||
2.1.x | ||
6.0.x | ||
# Build Release and test | ||
- name: Build Release | ||
run: dotnet build Adyen | ||
- name: Run test suite netcoreapp2.1 | ||
run: dotnet test --no-build -c Debug -f netcoreapp2.1 Adyen.Test/Adyen.Test.csproj | ||
- name: Run test suite net6.0 | ||
run: dotnet test --no-build -c Debug -f net6.0 Adyen.Test/Adyen.Test.csproj | ||
# Pack Release | ||
- name: Pack | ||
run: dotnet pack Adyen --no-build --configuration Release --output nuget | ||
# Publish Package | ||
- name: Publish Nuget | ||
run: dotnet nuget push nuget/*.nupkg --api-key ${{ secrets.ADYEN_NUGET }} --source "nuget.org" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,10 @@ | ||
$script = <<-SCRIPT | ||
sudo rpm -Uvh https://packages.microsoft.com/config/rhel/7/packages-microsoft-prod.rpm | ||
echo "Run update" | ||
sudo yum update | ||
echo "Install dotnet core" | ||
sudo yum -y install dotnet-sdk-2.2 | ||
SCRIPT | ||
Vagrant.configure("2") do |config| | ||
config.vm.box = "centos/7" | ||
config.vm.box = "jeffnoxon/ubuntu-20.04-arm64" | ||
config.vm.network "private_network", ip: "192.168.58.30" | ||
config.vm.provider :parallels do |v| | ||
v.memory = "4096" | ||
v.cpus = 2 | ||
end | ||
config.vm.synced_folder '.', '/home/vagrant/adyen-dotnet-api-library', disabled: false | ||
config.vm.synced_folder '.', '/vagrant', disabled: true | ||
config.vm.network :forwarded_port, guest: 22, host: 3333 | ||
config.vm.provider :virtualbox do |vb| | ||
vb.name = "adyen-dotnet-api-library" | ||
vb.customize ["modifyvm", :id, "--memory", "1024", "--cpus", "2"] | ||
end | ||
config.vm.provision "shell", inline: $script | ||
end | ||
config.vm.network :forwarded_port, guest:9876, host: 9876 | ||
end |