Просмотр исходного кода

build: add MSVC setup for Windows and simplify CLI execution

沉默の金 5 месяцев назад
Родитель
Сommit
a56d1bedb2
1 измененных файлов с 10 добавлено и 7 удалено
  1. 10 7
      .github/workflows/build.yml

+ 10 - 7
.github/workflows/build.yml

@@ -132,6 +132,10 @@ jobs:
         with:
           python-version: '3.11'
           
+      - name: Setup MSVC
+        if: runner.os == 'Windows'
+        uses: ilammy/msvc-dev-cmd@v1
+
       - name: Install Python Dependencies
         run: pip install numpy scipy
           
@@ -247,14 +251,13 @@ jobs:
           
           # Define runner helper
           run_cli() {
-              if [[ "$RUNNER_OS" == "Windows" ]]; then
-                  WIN_EXE=$(cygpath -w "$CLI_PATH")
-                  cmd //c "$WIN_EXE" "$@"
-              else
-                  (cd "$CLI_DIR" && ./$CLI_NAME "$@")
-              fi
+              echo "Executing: ./$CLI_NAME $@"
+              (cd "$CLI_DIR" && ./$CLI_NAME "$@")
           }
-
+          
+          # Debug PATH
+          echo "PATH: $PATH"
+          
           # 1. Test --help
           echo "[1/4] Testing --help..."
           run_cli --help