Files
Programming-Contests/files/ide/acpc-eclipse
T
2026-10-15 20:44:05 -03:00

14 lines
549 B
Bash

#!/bin/bash
# Initialize the supplied contest workspace once, also after a team-home reset.
set -eu
export PATH="/usr/local/lib/acpc-toolchain:$PATH"
workspace="$HOME/eclipse-workspace"
mkdir -p "$workspace"
if [ ! -f "$workspace/.acpc-imported" ]; then
/opt/eclipse/eclipse -nosplash -data "$workspace" \
-application org.eclipse.cdt.managedbuilder.core.headlessbuild \
-import "$HOME/contest" -no-indexer > "$workspace/import.log" 2>&1
touch "$workspace/.acpc-imported"
fi
exec /opt/eclipse/eclipse -data "$workspace" "$@"