forked from openai/SWELancer-Benchmark
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup_eval.yml
More file actions
65 lines (57 loc) · 1.95 KB
/
setup_eval.yml
File metadata and controls
65 lines (57 loc) · 1.95 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
---
- hosts: localhost
become: true
tasks:
- name: Ensure ISSUE_ID environment variable is set
assert:
that:
- lookup('env', 'ISSUE_ID') is not none
fail_msg: "The environment variable ISSUE_ID is not set."
- name: Get the commit ID for the issue
shell: |
ISSUE_ID={{ lookup('env', 'ISSUE_ID') }}
cat /app/tests/issues/$ISSUE_ID/commit_id.txt
register: commit_id
- name: Read the patch file content
slurp:
src: "/app/tests/issues/{{ lookup('env', 'ISSUE_ID') }}/bug_reintroduce.diff"
register: patch_content
- name: Apply the patch file if not empty
shell: |
ISSUE_ID={{ lookup('env', 'ISSUE_ID') }}
patch -p1 < /app/tests/issues/$ISSUE_ID/bug_reintroduce.diff
args:
chdir: /app/expensify
when:
- (patch_content.content | b64decode | trim) | length > 0
- name: Install npm dependencies
shell: |
source /root/.nvm/nvm.sh
npm install
args:
chdir: /app/expensify
executable: /bin/bash
- name: Check if the webpack.dev.ts file exists
ansible.builtin.stat:
path: /app/expensify/config/webpack/webpack.dev.ts
register: webpack_file_ts
- name: Compile Development Webpack (TypeScript)
shell: |
source /root/.nvm/nvm.sh
npx webpack --config ./config/webpack/webpack.dev.ts
args:
chdir: /app/expensify
executable: /bin/bash
when: webpack_file_ts.stat.exists
- name: Check if the webpack.dev.js file exists
ansible.builtin.stat:
path: /app/expensify/config/webpack/webpack.dev.js
register: webpack_file_js
- name: Compile Development Webpack (JavaScript)
shell: |
source /root/.nvm/nvm.sh
npx webpack --config ./config/webpack/webpack.dev.js
args:
chdir: /app/expensify
executable: /bin/bash
when: webpack_file_js.stat.exists