Skip to content

Commit c9d99a1

Browse files
committed
feat: workflow for solver
1 parent a3bb1b7 commit c9d99a1

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

.github/workflows/solve_problem.yml

+34
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: Solve KNSP With CP-SAT
2+
3+
on:
4+
# Allows you to run this workflow manually from the Actions tab
5+
workflow_dispatch:
6+
inputs:
7+
problem:
8+
description: 'Name of the problem to solve'
9+
required: true
10+
default: 'gcp_app_10_node_9'
11+
12+
jobs:
13+
build:
14+
runs-on: ubuntu-latest
15+
steps:
16+
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
17+
- uses: actions/checkout@v4
18+
19+
# Setup the environment
20+
- name: Set up Python 3.12
21+
uses: actions/setup-python@v5
22+
with:
23+
python-version: "3.12"
24+
cache: 'pip' # caching pip dependencies
25+
26+
- name: Install dependencies
27+
run: |
28+
python -m pip install --upgrade pip
29+
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
30+
if [ -f test-requirements.txt ]; then pip install -r test-requirements.txt; fi
31+
python -m pip install ./models+or-tools
32+
33+
- name: Run the script
34+
run: python ./models_or-tools/problems/${{ github.event.inputs.problem }}.py

0 commit comments

Comments
 (0)