Skip to content

Commit

Permalink
CI: build snap packages with stockdotnet6+xbuild
Browse files Browse the repository at this point in the history
  • Loading branch information
aarani committed Aug 28, 2023
1 parent 0488e66 commit d27a07b
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 8 deletions.
9 changes: 4 additions & 5 deletions .github/workflows/CI.yml
Original file line number Diff line number Diff line change
Expand Up @@ -640,15 +640,14 @@ jobs:
- name: Install snap tools
run: |
sudo apt update
sudo ./scripts/install_mono_from_microsoft_deb_packages.sh
./scripts/install_snapcraft.sh
# hack to disable dotnet detection (can't use apt purge because github VM seems to have it installed in different way)
# NOTE: you might think an easier way to do this would be use container:\nimage: ubuntu22.04 and then not install dotnet pkg,
# hack to disable msbuild detection
# NOTE: you might think an easier way to do this would be use container:\nimage: ubuntu22.04 and then not install msbuild,
# but that doesn't work because we get the following error when trying to install snapcraft via `snap install --classic`:
# > error: cannot communicate with server: Post "http://localhost/v2/snaps/snapcraft": dial unix /run/snapd.socket: connect: no such file or directory
- name: HACK to emulate dotnet uninstall
run: sudo rm `which dotnet`
- name: HACK to emulate msbuild uninstall
run: sudo rm `which msbuild`

- name: Generate snap package
run: |
Expand Down
2 changes: 1 addition & 1 deletion scripts/snap_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ set -euxo pipefail

# this is the equivalent of using the 'build-packages' (not stage-packages) section in snapcraft
# but as we're not using the 'make' plugin, we need to this manually now
DEBIAN_FRONTEND=noninteractive sudo apt install -y fsharp build-essential pkg-config cli-common-dev mono-devel libgtk2.0-cil-dev
DEBIAN_FRONTEND=noninteractive sudo apt install -y fsharp build-essential pkg-config cli-common-dev mono-devel libgtk2.0-cil-dev dotnet6

# just in case this is a retry-run, we want to clean artifacts from previous try
rm -rf ./staging
Expand Down
2 changes: 0 additions & 2 deletions scripts/snap_install_as_docker.sh
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,5 @@ echo " done"
$SUDO docker exec $CONTNAME snap install core || clean_up
echo "container $CONTNAME started ..."

$SUDO docker exec $CONTNAME scripts/install_mono_from_microsoft_deb_packages.sh

print_info
rm_builddir

0 comments on commit d27a07b

Please sign in to comment.