Skip to content

Commit

Permalink
Allow spaces in $DNF_INSTALL
Browse files Browse the repository at this point in the history
Resolves: #74

Co-authored-by: Miro Hrončok <[email protected]>
  • Loading branch information
frenzymadness and hroncok committed Nov 25, 2024
1 parent 252397a commit 6fa7bfa
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-and-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ jobs:
env:
TOXENV: ${{ matrix.toxenv }}
run: |
docker run --rm --platform linux/${{ matrix.arch }} -e DNF_INSTALL="libffi-devel pkgconfig(libgit2) /usr/bin/cowsay" fedorapython/fedora-python-tox:${{ matrix.arch }} sh -c "/run_tests.sh; pip install -I --no-deps --compile --no-binary :all: cffi pygit2~=1.14.0 && cowsay DONE"
docker run --rm --platform linux/${{ matrix.arch }} -e DNF_INSTALL="libffi-devel 'pkgconfig(libgit2) >= 1.7' /usr/bin/cowsay" fedorapython/fedora-python-tox:${{ matrix.arch }} sh -c "/run_tests.sh; pip install -I --no-deps --compile --no-binary :all: cffi pygit2~=1.14.0 && cowsay DONE"
- name: Test external project with WORKDIR
run: |
docker run --rm --platform linux/${{ matrix.arch }} -e TOXENV=py310-minimal -e GIT_URL=https://github.com/trezor/trezor-firmware.git -e WORKDIR=python fedorapython/fedora-python-tox:${{ matrix.arch }}
Expand Down
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -179,6 +179,9 @@ You can install packages by any RPM *Provides*, for example:
* pkgconfig names, e.g. `pkgconfig(libgit2)`, or
* commands, e.g. `/usr/bin/cowsay`.

Complex specifications including spaces have to be enclosed in single quotes
inside the double quotes. For example: `-e DNF_INSTALL="libyaml-devel 'pytest > 7'"`

# WORKDIR

If your `tox.ini` file is not in the root directory of your project, set `WORKDIR` to the path you want to cd to before the tests are executed.
Expand Down
2 changes: 1 addition & 1 deletion run_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if [ ! -z $GIT_URL ]; then
fi

if [ ! -z "$DNF_INSTALL" ]; then
dnf -y --setopt=tsflags=nodocs --setopt=deltarpm=false install $DNF_INSTALL
echo $DNF_INSTALL | xargs dnf -y --setopt=tsflags=nodocs --setopt=deltarpm=false install
fi

# Mark the current directory as safe for Git:
Expand Down

0 comments on commit 6fa7bfa

Please sign in to comment.