Skip to content

Commit e3dfe5d

Browse files
committed
Update deployment
1 parent c3a871a commit e3dfe5d

2 files changed

Lines changed: 14 additions & 3 deletions

File tree

.github/workflows/deploy-tutorials.yaml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,21 @@ jobs:
3131
- name: Check if tutorial changed
3232
id: changes
3333
run: |
34-
if git diff --name-only ${{ github.event.before }}..${{ github.sha }} | grep -q "^${{ matrix.tutorial.path }}/"; then
34+
# Always deploy if manually triggered
35+
if [ "${{ github.event_name }}" == "workflow_dispatch" ]; then
3536
echo "changed=true" >> $GITHUB_OUTPUT
37+
exit 0
38+
fi
39+
40+
# For push events, check if files changed
41+
if [ -n "${{ github.event.before }}" ] && [ "${{ github.event.before }}" != "null" ]; then
42+
if git diff --name-only ${{ github.event.before }}..${{ github.sha }} | grep -q "^${{ matrix.tutorial.path }}/"; then
43+
echo "changed=true" >> $GITHUB_OUTPUT
44+
else
45+
echo "changed=false" >> $GITHUB_OUTPUT
46+
fi
3647
else
37-
echo "changed=false" >> $GITHUB_OUTPUT
48+
echo "changed=true" >> $GITHUB_OUTPUT
3849
fi
3950
4051
- name: Deploy ${{ matrix.tutorial.name }}

tutorials/tutorial-01-basics/app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ def _(mo):
1212
1313
This notebook demonstrates how to use the flixopt framework to model a minimalistic energy system
1414
with a boiler, heat demand, and natural gas supply.
15-
THis has been updated again
15+
THis has been updated again, again
1616
"""
1717
)
1818
return

0 commit comments

Comments
 (0)