From dc1daf7ed491ea9560145308ac96020e94576c32 Mon Sep 17 00:00:00 2001
From: Audric Ackermann <audric@loki.network>
Date: Thu, 27 Apr 2023 16:51:26 +1000
Subject: [PATCH] chore: include libsession node module into packaged apps

---
 .github/workflows/build-binaries.yml | 6 +++---
 .github/workflows/pull-request.yml   | 6 +++---
 .github/workflows/release.yml        | 6 +++---
 package.json                         | 1 +
 4 files changed, 10 insertions(+), 9 deletions(-)

diff --git a/.github/workflows/build-binaries.yml b/.github/workflows/build-binaries.yml
index a5a438b05..c85c95b76 100644
--- a/.github/workflows/build-binaries.yml
+++ b/.github/workflows/build-binaries.yml
@@ -15,7 +15,7 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        os: [windows-2022, macos-latest, ubuntu-20.04]
+        os: [windows-2022, macos-11, ubuntu-20.04]
     env:
       SIGNAL_ENV: production
       GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -43,7 +43,7 @@ jobs:
         if: runner.os == 'Windows'
         uses: crazy-max/ghaction-chocolatey@v1.4.2
         with:
-          args: install python2 visualcpp-build-tools -y
+          args: install python2 -y
 
       # Not having this will break the windows build because the PATH won't be set by msbuild.
       - name: Add msbuild to PATH
@@ -55,7 +55,7 @@ jobs:
         run: |
           npm install --global node-gyp@latest
           npm config set python python2.7
-          npm config set msvs_version 2017
+          npm config set msvs_version 2022
 
       - name: Install Desktop node_modules
         if: steps.cache-desktop-modules.outputs.cache-hit != 'true'
diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml
index c274ae199..d6b9c1405 100644
--- a/.github/workflows/pull-request.yml
+++ b/.github/workflows/pull-request.yml
@@ -12,7 +12,7 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        os: [windows-2022, macos-latest, ubuntu-20.04]
+        os: [windows-2022, macos-11, ubuntu-20.04]
     env:
       SIGNAL_ENV: production
       GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -39,7 +39,7 @@ jobs:
         if: runner.os == 'Windows'
         uses: crazy-max/ghaction-chocolatey@v1.4.2
         with:
-          args: install python2 visualcpp-build-tools -y
+          args: install python2 -y
 
       #Not having this will break the windows build because the PATH won't be set by msbuild.
       - name: Add msbuild to PATH
@@ -51,7 +51,7 @@ jobs:
         run: |
           npm install --global node-gyp@latest
           npm config set python python2.7
-          npm config set msvs_version 2017
+          npm config set msvs_version 2022
 
       - name: Install Desktop node_modules
         if: steps.cache-desktop-modules.outputs.cache-hit != 'true'
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 66bb0ad5a..1e83298cc 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -12,7 +12,7 @@ jobs:
     strategy:
       fail-fast: false
       matrix:
-        os: [windows-2022, macos-latest, ubuntu-20.04]
+        os: [windows-2022, macos-11, ubuntu-20.04]
     env:
       SIGNAL_ENV: production
       GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -40,7 +40,7 @@ jobs:
         if: runner.os == 'Windows'
         uses: crazy-max/ghaction-chocolatey@v1.4.2
         with:
-          args: install python2 visualcpp-build-tools -y
+          args: install python2 -y
 
       #Not having this will break the windows build because the PATH won't be set by msbuild.
       - name: Add msbuild to PATH
@@ -52,7 +52,7 @@ jobs:
         run: |
           npm install --global node-gyp@latest
           npm config set python python2.7
-          npm config set msvs_version 2017
+          npm config set msvs_version 2022
 
       - name: Install Desktop node_modules
         if: steps.cache-desktop-modules.outputs.cache-hit != 'true'
diff --git a/package.json b/package.json
index 4f54eec2c..cab8729a3 100644
--- a/package.json
+++ b/package.json
@@ -349,6 +349,7 @@
       "!**/*.ts",
       "node_modules/spellchecker/build/Release/*.node",
       "node_modules/websocket/build/Release/*.node",
+      "node_modules/libsession_util_nodejs/build/Release/*.node",
       "node_modules/socks/build/*.js",
       "node_modules/socks/build/common/*.js",
       "node_modules/socks/build/client/*.js",