ds
Some checks failed
Dropshell Test / Build_and_Test (push) Failing after 12s

This commit is contained in:
Your Name
2025-05-25 18:14:15 +12:00
parent f45d9a33ed
commit d71ba38754
10 changed files with 10878 additions and 149 deletions

View File

@ -1,5 +1,7 @@
#!/bin/bash
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )"
# Exit on error
set -e
@ -53,24 +55,6 @@ if ! command -v make &> /dev/null; then
exit 1
fi
# Check if pkg-config is installed
if ! command -v pkg-config &> /dev/null; then
print_error "pkg-config is not installed. Please install pkg-config first."
print_warning "On Ubuntu/Debian: sudo apt-get install pkg-config"
print_warning "On Fedora: sudo dnf install pkg-config"
print_warning "On Arch: sudo pacman -S pkg-config"
exit 1
fi
# Check if ncurses is installed
if ! pkg-config --exists ncurses; then
print_error "ncurses is not installed. Please install ncurses first."
print_warning "On Ubuntu/Debian: sudo apt-get install libncurses-dev"
print_warning "On Fedora: sudo dnf install ncurses-devel"
print_warning "On Arch: sudo pacman -S ncurses"
exit 1
fi
# Configure with CMake
print_status "Configuring with CMake..."
cmake .. -DCMAKE_BUILD_TYPE=Debug
@ -83,21 +67,14 @@ make -j"$JOBS"
# Check if build was successful
if [ $? -eq 0 ]; then
print_status "Build successful!"
print_status "Binary location: $(pwd)/dropshell"
else
print_error "Build failed!"
exit 1
fi
print_status "Auto-installing dropshell..."
sudo make install
if [ $? -eq 0 ]; then
print_status "Installation successful!"
else
print_error "Installation failed!"
exit 1
fi
print_status "Auto-installing dropshell locally..."
mkdir -p "${HOME}/.local/bin"
cp "$SCRIPT_DIR/build/dropshell" "${HOME}/.local/bin/dropshell"
# Return to original directory
cd ..