| 1 | #!/bin/bash |
| 2 | # |
| 3 | # IMPORTANT: See |
| 4 | # https://gnome.pages.gitlab.gnome.org/librsvg/devel-docs/ci.html#container-image-version |
| 5 | |
| 6 | # Activate the Python virtual environment for CI scripts. |
| 7 | # |
| 8 | # We test for the presence of the file, since when first creating the container images for CI, |
| 9 | # the venv has not been created yet. This is mostly a hack to allow having a single "env.sh" |
| 10 | # script instead of one for container creation and one for CI jobs. |
| 11 | if [ -f /usr/local/python/bin/activate ]; then |
| 12 | source /usr/local/python/bin/activate |
| 13 | fi |
| 14 | |
| 15 | export RUSTUP_HOME='/usr/local/rustup' |
| 16 | export PATH=$PATH:/usr/local/cargo/bin |
| 17 | |
| 18 | if [ ! -v CARGO_HOME ]; then |
| 19 | export CARGO_HOME=/srv/project/cargo_cache |
| 20 | mkdir -p /srv/project/cargo_cache |
| 21 | fi |