Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ env:

jobs:
build:
runs-on: ubuntu-24.04
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/clang_format.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ on:
jobs:
formatting-check:
name: Formatting Check
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
strategy:
matrix:
path:
Expand Down
8 changes: 6 additions & 2 deletions .github/workflows/cmake_examples.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,11 @@ env:

jobs:
build:
runs-on: ubuntu-24.04
strategy:
matrix:
os: [ubuntu-latest, macos-latest]

runs-on: ${{ matrix.os }}

steps:
- uses: actions/checkout@v4
Expand All @@ -23,7 +27,7 @@ jobs:
- name: Build
working-directory: ${{github.workspace}}/examples
run: cmake --build build

- name: Stalingrado
working-directory: ${{github.workspace}}/examples
run: make stalingrado
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cmake_install.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:

jobs:
build:
runs-on: ubuntu-24.04
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/cmake_test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ env:

jobs:
build:
runs-on: ubuntu-24.04
runs-on: ubuntu-latest

steps:
- name: Update apt repo
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codacy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ jobs:
security-events: write # for github/codeql-action/upload-sarif to upload SARIF results
actions: read # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status
name: Codacy Security Scan
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
steps:
# Checkout the repository to the GitHub Actions runner
- name: Checkout code
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
# - https://gh.io/supported-runners-and-hardware-resources
# - https://gh.io/using-larger-runners
# Consider using larger runners for possible analysis time improvements.
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-24.04' }}
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
permissions:
actions: read
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/flawfinder.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ on:
jobs:
flawfinder:
name: Flawfinder
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/gh-pages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:

jobs:
build-and-deploy:
runs-on: ubuntu-24.04
runs-on: ubuntu-latest

steps:
- name: Checkout repository
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/profile_exec_time.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ env:

jobs:
build:
runs-on: ubuntu-24.04
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/profile_mem_usage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ env:

jobs:
build:
runs-on: ubuntu-24.04
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pylint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:

jobs:
build:
runs-on: ubuntu-24.04
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up Python 3.10
Expand Down
11 changes: 10 additions & 1 deletion examples/slow_charge_rb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@
namespace fs = std::filesystem;

#include <thread>
#ifdef __APPLE__
#define thread_t std::thread
#else
#define thread_t std::jthread
#endif
#include <atomic>

std::atomic<unsigned int> progress{0};
Expand Down Expand Up @@ -183,7 +188,7 @@ int main(int argc, char** argv) {
// std::vector<int> deltas;

// lauch progress bar
std::jthread t([]() {
thread_t t([]() {
while (progress < MAX_TIME && !bExitFlag) {
printLoadingBar(progress, MAX_TIME);
std::this_thread::sleep_for(std::chrono::milliseconds(1500));
Expand Down Expand Up @@ -299,5 +304,9 @@ int main(int argc, char** argv) {
std::cout << '\n';
std::cout << "Done." << std::endl;

#ifdef __APPLE__
t.join();
#endif

return 0;
}
11 changes: 10 additions & 1 deletion examples/slow_charge_tl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@
namespace fs = std::filesystem;

#include <thread>
#ifdef __APPLE__
#define thread_t std::thread
#else
#define thread_t std::jthread
#endif
#include <atomic>

std::atomic<unsigned int> progress{0};
Expand Down Expand Up @@ -287,7 +292,7 @@ int main(int argc, char** argv) {
// std::vector<int> deltas;

// lauch progress bar
std::jthread t([]() {
thread_t t([]() {
while (progress < MAX_TIME && !bExitFlag) {
printLoadingBar(progress, MAX_TIME);
std::this_thread::sleep_for(std::chrono::milliseconds(1500));
Expand Down Expand Up @@ -447,5 +452,9 @@ int main(int argc, char** argv) {
std::cout << '\n';
std::cout << "Done." << std::endl;

#ifdef __APPLE__
t.join();
#endif

return 0;
}
11 changes: 10 additions & 1 deletion examples/stalingrado.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@
#include <string>

#include <thread>
#ifdef __APPLE__
#define thread_t std::thread
#else
#define thread_t std::jthread
#endif
#include <atomic>

std::atomic<unsigned int> progress{0};
Expand Down Expand Up @@ -88,7 +93,7 @@ int main() {
dynamics.updatePaths();

// lauch progress bar
std::jthread t([MAX_TIME]() {
thread_t t([MAX_TIME]() {
while (progress < MAX_TIME) {
printLoadingBar(progress, MAX_TIME);
std::this_thread::sleep_for(std::chrono::milliseconds(1500));
Expand All @@ -113,5 +118,9 @@ int main() {
++progress;
}

#ifdef __APPLE__
t.join();
#endif

return 0;
}
Loading