#!/bin/bash echo "requires sudo to run eg: sudo ./ecat.sh" # Removing old repo if it exists if [ -e /etc/apt/sources.list.d/ighvh.sources ] then echo "removing ethercat repository file\n" rm /etc/apt/sources.list.d/ighvh.sources fi # Install ethercat repositories. echo "Install ethercat repository" mkdir -p /usr/local/share/keyrings/ wget -O- https://build.opensuse.org/projects/science:EtherLab/signing_keys/download?kind=gpg | gpg --dearmor | dd of=/etc/apt/trusted.gpg.d/science_EtherLab.gpg tee -a /etc/apt/sources.list.d/ighvh.sources > /dev/null <