Skip to content

Commit

Permalink
Add entrypoint file
Browse files Browse the repository at this point in the history
  • Loading branch information
jslane-h committed Dec 4, 2024
1 parent 9e4f096 commit 9bab626
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
7 changes: 1 addition & 6 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,4 @@ WORKDIR /app
COPY . /app

# Find directories containing measure.py and run tests'
RUN echo $GITHUB_WORKSPACE
RUN openstudio measure -t ./lib/measures >> $GITHUB_WORKSPACE/measure_check_output.txt
RUN bash -c "\
for dir in \$(find . -type f -name 'measure.py' -exec dirname {} \; | sort -u); do \
pytest \$dir >> $GITHUB_WORKSPACE/pytest_output.txt; \
done"
ENTRYPOINT ["entrypoint.sh"]
9 changes: 9 additions & 0 deletions entrypoint.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/sh -l

echo $GITHUB_WORKSPACE

openstudio measure -t ./lib/measures >> $GITHUB_WORKSPACE/measure_check_output.txt

for dir in \$(find . -type f -name 'measure.py' -exec dirname {} \; | sort -u); do \
pytest \$dir >> $GITHUB_WORKSPACE/pytest_output.txt; \
done

0 comments on commit 9bab626

Please sign in to comment.