Initial import of ORISYS arm workstation
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
name: CI-Cpp
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
branches: [main]
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
env:
|
||||
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: "true"
|
||||
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
|
||||
BUILD_TYPE: Release
|
||||
|
||||
jobs:
|
||||
ci-cpp:
|
||||
name: CI-Cpp @ ${{ matrix.os }}
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os:
|
||||
- ubuntu-22.04
|
||||
- ubuntu-22.04-arm
|
||||
- ubuntu-24.04
|
||||
- ubuntu-24.04-arm
|
||||
- macos-14
|
||||
- windows-2022
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: ./.github/workflows/shared_cpp_steps
|
||||
@@ -0,0 +1,37 @@
|
||||
name: CI-Python
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [main]
|
||||
pull_request:
|
||||
branches: [main]
|
||||
workflow_dispatch:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
|
||||
env:
|
||||
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: "true"
|
||||
|
||||
jobs:
|
||||
ci-python:
|
||||
name: CI-Python @ ${{ matrix.os }} (${{ matrix.python-version }})
|
||||
runs-on: ${{ matrix.os }}
|
||||
strategy:
|
||||
fail-fast: false
|
||||
matrix:
|
||||
os:
|
||||
- ubuntu-22.04
|
||||
- ubuntu-22.04-arm
|
||||
- ubuntu-24.04
|
||||
- ubuntu-24.04-arm
|
||||
- macos-14
|
||||
- windows-2022
|
||||
python-version:
|
||||
- "3.10"
|
||||
- "3.12"
|
||||
steps:
|
||||
- uses: actions/checkout@v6
|
||||
- uses: ./.github/workflows/shared_python_steps
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
@@ -0,0 +1,50 @@
|
||||
name: "Shared Check Steps for C++"
|
||||
runs:
|
||||
using: "composite"
|
||||
# Note: working directory will be reset to the repo root for each new step
|
||||
steps:
|
||||
# Use a fixed CMake version
|
||||
- name: Set up CMake
|
||||
uses: jwlawson/actions-setup-cmake@v2
|
||||
with:
|
||||
cmake-version: '3.28.3'
|
||||
|
||||
# Build and install all dependencies to RDK installation directory.
|
||||
- name: Build and install dependencies
|
||||
shell: bash
|
||||
run: |
|
||||
cmake --version
|
||||
cd thirdparty
|
||||
bash build_and_install_dependencies.sh ~/rdk_install 8
|
||||
|
||||
# Configure CMake, then build and install flexiv_rdk library to RDK installation directory.
|
||||
- name: Build and install library
|
||||
shell: bash
|
||||
run: |
|
||||
mkdir -p build && cd build
|
||||
cmake .. -DCMAKE_INSTALL_PREFIX=~/rdk_install
|
||||
cmake --build . --target install --config Release
|
||||
|
||||
# Find and link to flexiv_rdk library, then build all examples.
|
||||
- name: Build examples
|
||||
shell: bash
|
||||
run: |
|
||||
cd example
|
||||
mkdir -p build && cd build
|
||||
cmake .. -DCMAKE_PREFIX_PATH=~/rdk_install
|
||||
cmake --build . --config Release -j 8
|
||||
|
||||
# Find and link to flexiv_rdk library, then build all tests.
|
||||
- name: Build tests
|
||||
shell: bash
|
||||
run: |
|
||||
cd test
|
||||
mkdir -p build && cd build
|
||||
cmake .. -DCMAKE_PREFIX_PATH=~/rdk_install
|
||||
cmake --build . --config Release -j 8
|
||||
|
||||
- name: Run unit tests
|
||||
shell: bash
|
||||
run: |
|
||||
cd test/build
|
||||
ctest --output-on-failure
|
||||
@@ -0,0 +1,41 @@
|
||||
name: "Shared Check Steps for Python"
|
||||
inputs:
|
||||
python-version:
|
||||
description: "Python version used for example compilation checks"
|
||||
required: true
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Set up Python
|
||||
uses: actions/setup-python@v6
|
||||
with:
|
||||
python-version: ${{ inputs.python-version }}
|
||||
|
||||
- name: Install latest flexivrdk
|
||||
shell: bash
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
python -m pip install flexivrdk
|
||||
|
||||
- name: Byte-compile Python examples
|
||||
shell: bash
|
||||
run: |
|
||||
python - <<'PY'
|
||||
from pathlib import Path
|
||||
import py_compile
|
||||
|
||||
root = Path('example_py')
|
||||
files = sorted(
|
||||
path for path in root.glob('*.py')
|
||||
if path.name.startswith('basics') or path.name.startswith('intermediate')
|
||||
)
|
||||
|
||||
for path in files:
|
||||
py_compile.compile(str(path), doraise=True)
|
||||
print(f'py_compile OK: {path}')
|
||||
PY
|
||||
|
||||
- name: Run unit tests
|
||||
shell: bash
|
||||
run: |
|
||||
python test/test_robot_constructor.py -v
|
||||
Reference in New Issue
Block a user