From 9f5732b016c6179558ead4400176ac0b0b30a881 Mon Sep 17 00:00:00 2001 From: dekken Date: Sun, 5 Apr 2026 12:46:29 +0200 Subject: [PATCH 1/3] windwoes --- .github/workflows/build.yml | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 11cc812..e9279bb 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -36,8 +36,8 @@ jobs: run: | $CURL_GET -o mkn ${PATH_GET}/mkn_nix chmod +x mkn - KLOG=2 ./mkn clean build run -dtOa "-std=c++20 -fPIC" - KLOG=2 ./mkn clean build -dtOa "-std=c++20 -fPIC" -p test_module + KLOG=3 ./mkn clean build run -dtOa "-std=c++20 -fPIC" + KLOG=3 ./mkn clean build -dtOa "-std=c++20 -fPIC" -p test_module python3 -c "import test_module as tm; tm.lol()" macos: @@ -60,7 +60,9 @@ jobs: run: | $CURL_GET -o mkn ${PATH_GET}/mkn_arm_osx chmod +x mkn - KLOG=2 ./mkn clean build run -dtOa "-std=c++20 -fPIC" + KLOG=3 ./mkn clean build run -dtOa "-std=c++20 -fPIC" + KLOG=3 ./mkn clean build -dtOa "-std=c++20 -fPIC" -p test_module + python3 -c "import test_module as tm; tm.lol()" windows: runs-on: windows-latest @@ -87,5 +89,7 @@ jobs: run: | # /bin/link interferes with cl/link.exe bash -c "rm /bin/link" bash -c '$CURL_GET -o mkn.exe ${PATH_GET}/mkn.exe' - bash -c 'KLOG=2 ./mkn clean build run -dtOa "-EHsc -std:c++20"' - bash -c 'KLOG=2 ./mkn clean build run -dtOp test -a "-EHsc -std:c++20"' + bash -c 'KLOG=3 ./mkn clean build run -dtOa "-EHsc -std:c++20"' + bash -c 'KLOG=3 ./mkn clean build run -dtOp test -a "-EHsc -std:c++20"' + bash -c 'KLOG=3 ./mkn clean build -dtOa "-std:c++20 -EHsc" -p test_module' + python3 -c "import test_module as tm; tm.lol()" From 6fd3d4fb58c766a1610fe672f94a7cfcf5fe2173 Mon Sep 17 00:00:00 2001 From: dekken Date: Sun, 5 Apr 2026 21:22:29 +0200 Subject: [PATCH 2/3] ++ --- mod.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/mod.cpp b/mod.cpp index 0a8a856..0184500 100644 --- a/mod.cpp +++ b/mod.cpp @@ -104,7 +104,10 @@ std::string pyexec_for_string(std::string const& cmd) { KERR << ex; throw; } - return kul::String::LINES(pc.outs())[0]; // DROP EOL + auto ret = kul::String::LINES(pc.outs())[0]; + if(ret.back() == '\n') ret.pop_back(); + if(ret.back() == '\r') ret.pop_back(); + return ret; } class ModuleMaker : public maiken::Module { From 98f56a53dc0bec2a73554b2354b65fb601ca93ed Mon Sep 17 00:00:00 2001 From: dekken Date: Sun, 5 Apr 2026 23:41:12 +0200 Subject: [PATCH 3/3] ++ --- .github/workflows/build.yml | 46 +++++++++++-------------------------- 1 file changed, 13 insertions(+), 33 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index e9279bb..c890014 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -11,6 +11,7 @@ on: branches: [ master ] env: + MKN_LIB_LINK_LIB: 1 MKN_KUL_GIT_CO: --depth 1 CURL_GET: curl -fL --retry 3 --retry-delay 2 PATH_GET: https://github.com/mkn/mkn/releases/download/latest @@ -19,21 +20,15 @@ jobs: ubuntu: runs-on: ubuntu-latest strategy: - fail-fast: false - max-parallel: 4 matrix: python-version: ['3.14'] steps: - uses: actions/checkout@v6 - - uses: actions/setup-python@v6 with: python-version: ${{ matrix.python-version }} - architecture: x64 - - - env: - MKN_LIB_LINK_LIB: 1 - run: | + - run: | + set -ex $CURL_GET -o mkn ${PATH_GET}/mkn_nix chmod +x mkn KLOG=3 ./mkn clean build run -dtOa "-std=c++20 -fPIC" @@ -43,53 +38,38 @@ jobs: macos: runs-on: macos-latest strategy: - fail-fast: false - max-parallel: 4 matrix: python-version: ['3.14'] steps: - uses: actions/checkout@v6 - - uses: actions/setup-python@v6 with: python-version: ${{ matrix.python-version }} - architecture: x64 - - - env: - MKN_LIB_LINK_LIB: 1 - run: | + - run: | + set -ex $CURL_GET -o mkn ${PATH_GET}/mkn_arm_osx chmod +x mkn KLOG=3 ./mkn clean build run -dtOa "-std=c++20 -fPIC" - KLOG=3 ./mkn clean build -dtOa "-std=c++20 -fPIC" -p test_module - python3 -c "import test_module as tm; tm.lol()" + KLOG=3 ./mkn clean build run -dtOa "-std=c++20 -fPIC" -p test windows: runs-on: windows-latest strategy: - fail-fast: false - max-parallel: 4 matrix: python-version: ['3.14'] steps: - uses: actions/checkout@v6 - - uses: actions/setup-python@v6 with: python-version: ${{ matrix.python-version }} - architecture: x64 - - uses: ilammy/msvc-dev-cmd@v1 - with: - arch: amd64 - - env: MKN_CL_PREFERRED: 1 - shell: cmd + shell: bash run: | # /bin/link interferes with cl/link.exe - bash -c "rm /bin/link" - bash -c '$CURL_GET -o mkn.exe ${PATH_GET}/mkn.exe' - bash -c 'KLOG=3 ./mkn clean build run -dtOa "-EHsc -std:c++20"' - bash -c 'KLOG=3 ./mkn clean build run -dtOp test -a "-EHsc -std:c++20"' - bash -c 'KLOG=3 ./mkn clean build -dtOa "-std:c++20 -EHsc" -p test_module' - python3 -c "import test_module as tm; tm.lol()" + set -ex + rm /bin/link + $CURL_GET -o mkn.exe ${PATH_GET}/mkn.exe + KLOG=3 ./mkn clean build run -dtOa "-EHsc -std:c++20" + KLOG=3 ./mkn clean build run -dtOp test -a "-EHsc -std:c++20" + KLOG=3 ./mkn clean build -dtOa "-std:c++20 -EHsc" -p test_module