File tree Expand file tree Collapse file tree 3 files changed +1159
-30
lines changed Expand file tree Collapse file tree 3 files changed +1159
-30
lines changed Original file line number Diff line number Diff line change
1
+ name : Codeflash
2
+
3
+ on :
4
+ pull_request :
5
+ paths :
6
+ # So that this workflow only runs when code within the target module is modified
7
+ - ' src/galileo/**'
8
+ workflow_dispatch :
9
+
10
+ concurrency :
11
+ # Any new push to the PR will cancel the previous run, so that only the latest code is optimized
12
+ group : ${{ github.workflow }}-${{ github.ref }}
13
+ cancel-in-progress : true
14
+
15
+
16
+ jobs :
17
+ optimize :
18
+ name : Optimize new Python code
19
+ # Don't run codeflash on codeflash-ai[bot] commits, prevent duplicate optimizations
20
+ if : ${{ github.actor != 'codeflash-ai[bot]' }}
21
+ runs-on : ubuntu-latest
22
+ env :
23
+ CODEFLASH_API_KEY : ${{ secrets.CODEFLASH_API_KEY }}
24
+ CODEFLASH_PR_NUMBER : ${{ github.event.number }}
25
+
26
+ steps :
27
+ - name : 🛎️ Checkout
28
+ uses : actions/checkout@v4
29
+ with :
30
+ fetch-depth : 0
31
+ - name : 🐍 Set up Python
32
+ uses : actions/setup-python@v5
33
+ with :
34
+ python-version : ' 3.10'
35
+ - name : 📦 Install Dependencies
36
+ run : |
37
+ python -m pip install --upgrade pip
38
+ pip install poetry
39
+ poetry install --all-extras
40
+ - name : ⚡️Codeflash Optimization
41
+ run : |
42
+ poetry env use python
43
+ poetry run codeflash
You can’t perform that action at this time.
0 commit comments