From 6768d12fd7b6dba6baa42562ec97ecbab69ed89e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=94=D0=B0=D0=BD=D0=B8=D0=B8=D0=BB=20=D0=93=D1=80=D0=B0?= =?UTF-8?q?=D0=B1=D0=B0=D1=80=D1=8C?= Date: Thu, 18 Jun 2026 06:15:55 +0300 Subject: [PATCH] fix: update installation scripts to use the correct branch for cloning and installation --- README.md | 2 +- install.sh | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 40775a2..2bbf9f7 100644 --- a/README.md +++ b/README.md @@ -30,7 +30,7 @@ ROS 2 пакеты для управления роботом **KUKA LBR IIWA 7 Для установки запустите скрипт одной командой: ```bash -curl -fsSL https://gitverse.ru/api/repos/daniel-robotics/lightweight-cobot/raw/branch/main/install.sh +curl -fsSL https://gitverse.ru/api/repos/daniel-robotics/lightweight-cobot/raw/branch/dev/install.sh | bash ``` Скрипт установит ROS 2 Jazzy, Webots, соберёт рабочее пространство и установит CLI `cobot`. diff --git a/install.sh b/install.sh index 4a96dac..4a1845c 100644 --- a/install.sh +++ b/install.sh @@ -215,6 +215,8 @@ check_python() { resolve_install_dir() { local script_dir script_dir="$(cd "$(dirname "${BASH_SOURCE[0]:-$0}")" 2>/dev/null && pwd || pwd)" + local repo_branch + repo_branch="${REPO_BRANCH:-$(git -C "$script_dir" rev-parse --abbrev-ref HEAD 2>/dev/null || echo "master")}" # Running directly from inside the cloned repo (not via curl|bash) if [ -f "$script_dir/setup.py" ] && [ -d "$script_dir/.git" ]; then @@ -226,7 +228,7 @@ resolve_install_dir() { # Repo already cloned — pull instead of re-clone if [ -d "$INSTALL_DIR/.git" ]; then log_info "Repo already exists at $INSTALL_DIR — pulling latest..." - git -C "$INSTALL_DIR" pull --ff-only origin dev