summaryrefslogtreecommitdiffstats
path: root/slic3r
blob: 6683b9217579d212a3b5b49c2866c2eddfeb814c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#!/bin/bash

gitdir="$HOME/git/Slic3r"

#merged="$HOME/.Slic3r/config.ini.merged"
#truncate -s 0 "$merged"

TMPDIR="$(mktemp -d "/tmp/${0##*/}.XXXXXX")"
trap "rm -rf '${TMPDIR}'" EXIT TERM

locallib="$TMPDIR/local-lib-dir"

# I don't want to install the libs
mkdir -p "$locallib"
ln -sr "$gitdir/xs/blib/lib/Slic3r/" "$locallib/Slic3r"
ln -sr "$gitdir/xs/blib/arch/auto/" "$locallib/auto"

for config in "$HOME"/.Slic3r/*/config.ini; do
	opts+=(--load "$config")
	#cat "$config" >> "$merged"
done

#opts+=(--load "$merged")

perl -I"$locallib" "$gitdir/slic3r.pl" "${opts[@]}" "$@"