diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index f293a825..e852435b 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -14,11 +14,11 @@ jobs: image: defaultwriter/c-image-repo:latest steps: - uses: actions/checkout@v4 - with: - submodules: true - fetch-depth: 0 - - name: config - run: git config --global --add safe.directory ${GITHUB_WORKSPACE} + # with: + # submodules: true + # fetch-depth: 0 + # - name: config + # run: git config --global --add safe.directory ${GITHUB_WORKSPACE} - name: coverage run: ./bin/coverageall.sh --all --clean - name: sonarscanner diff --git a/Dockerfile b/Dockerfile index db63febd..fd41b8fe 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,36 +1,11 @@ FROM ubuntu:24.04 -ENV TZ=Europe/Istanbul +ENV TZ=Europe/Moscow -# Install sudo and other necessary packages RUN ln -snf /usr/share/zoneinfo/"$TZ" /etc/localtime && echo "$TZ" > /etc/timezone && \ apt -y update && \ export DEBIAN_FRONTEND=noninteractive && \ - apt -y install --no-install-recommends -y \ - build-essential \ - ca-certificates \ - nodejs \ - npm \ - python3 \ - python3-venv \ - python3-virtualenv \ - clangd \ - cmake \ - curl \ - g++ \ - gcc \ - gdb \ - gettext-base \ - git \ - gnupg \ - lcov \ - lldb \ - lsb-release \ - make \ - ninja-build \ - software-properties-common \ - sudo \ - wget && \ + apt -y install --no-install-recommends -y git ca-certificates gcc g++ make cmake ninja-build lcov && \ apt -y upgrade && \ apt autoclean -y && \ apt autoremove -y && \ @@ -45,6 +20,3 @@ WORKDIR /workspace # Copy all source files needed to run the initialization COPY bin /workspace/bin - -# Run the initialization script -RUN ./bin/init.sh --init --lcov --setup diff --git a/bin/library/cmake.sh b/bin/library/cmake.sh index 6b420366..a5f2279f 100755 --- a/bin/library/cmake.sh +++ b/bin/library/cmake.sh @@ -84,7 +84,7 @@ function get-cmake() { if [[ "${cmake}" == "" ]]; then cmake=$(command -v cmake) fi - echo ${cmake} + echo "${cmake}" } function get-targets() { @@ -241,21 +241,20 @@ function get-config() { cmake=$(get-cmake) if [[ "${cmake}" == "" ]]; then - echo cmake not found. please run "${pwd}/bin/utils/install.sh" --cmake - exit 8 + cmake="cmake" fi if [[ ! -d "${pwd}/config" ]]; then exec >/dev/null 2>&1 build="${pwd}/config" - ${cmake} \ + echo $(${cmake} \ -DCMAKE_EXPORT_COMPILE_COMMANDS:BOOL=TRUE \ -DTARGETS:BOOL=ON \ "${cmake-options}" \ -S"${pwd}" \ -B"${build}" \ - -G "Ninja" >/dev/null 2>&1 + -G "Ninja" >/dev/null 2>&1) # exec 1>&2 2>&- fi