Skip to content

Commit 6b86b55

Browse files
docs: format README
1 parent 7a9c108 commit 6b86b55

1 file changed

Lines changed: 63 additions & 46 deletions

File tree

README.md

Lines changed: 63 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,39 @@
1-
# Decades of GNU Patch and Git Cherry-Pick: Can We Do Better?
1+
# Decades of GNU Patch and Git Cherry-Pick: Can We Do Better?
22

3-
This is the reproduction package for our paper _Decades of GNU Patch and Git Cherry-Pick: Can We Do Better?_ which has been accepted to the 48th International Conference on Software Engineering (ICSE 2026).
3+
This is the reproduction package for our paper _Decades of GNU Patch and Git Cherry-Pick: Can We Do Better?_ which has been accepted to the 48th International Conference on Software Engineering (ICSE 2026).
44

55
## Content
6-
The reproduction package consists of three main parts:
76

8-
1. [__mpatch__](/mpatch/README.md): The implementation of our novel match-based patcher, written in Rust.
9-
2. [__Mined cherries__](dataset/): Our dataset of cherry picks mined from 5,000 GitHub repositories.
10-
3. [__Empirical evaluation__](src/main/kotlin/org/variantsync/evaluation/PatcherEvaluationMain.kt): Our empirical evaluation of different language-agnostic patchers.
7+
The reproduction package consists of three main parts:
8+
9+
1. [**mpatch**](/mpatch/README.md): The implementation of our novel match-based patcher, written in Rust.
10+
2. [**Mined cherries**](dataset/): Our dataset of cherry picks mined from 5,000 GitHub repositories.
11+
3. [**Empirical evaluation**](src/main/kotlin/org/variantsync/evaluation/PatcherEvaluationMain.kt): Our empirical evaluation of different language-agnostic patchers.
1112

1213
## Requirements
14+
1315
Software Requirements
16+
1417
- [Docker](https://www.docker.com/)
1518

1619
Hardware Requirements
17-
- We recommend running the evaluation on a system with at least __64GB__ of primary memory (RAM).
20+
21+
- We recommend running the evaluation on a system with at least **64GB** of primary memory (RAM).
1822
- 100GB—2TB of free drive space, depending on the configuration of the Docker image.
1923

2024
> [!WARNING]
2125
> The used storage medium should be very fast, e.g., M.2 NVMe SSD with 5000 MB/s, otherwise the evaluation may take an extremely long time.
2226
2327
Other Requirements
24-
- A stable internet connection.
2528

29+
- A stable internet connection.
2630

2731
## Installation
2832

2933
### [Optional] Configuration
30-
Before building the Docker image, you may __optionally__ configure how the evaluation is executed.
31-
To this end, we provide two configuration files: [config-reproduction.properties](docker/config-reproduction.properties) for the configuration of the reproduction of the entire evaluation, and [config-verification.properties](docker/config-verification) for the verification of the correct installation of the reproduction package.
34+
35+
Before building the Docker image, you may **optionally** configure how the evaluation is executed.
36+
To this end, we provide two configuration files: [config-reproduction.properties](docker/config-reproduction.properties) for the configuration of the reproduction of the entire evaluation, and [config-verification.properties](docker/config-verification) for the verification of the correct installation of the reproduction package.
3237

3338
Depending on the available hardware, you may need to adjust the following settings:
3439

@@ -37,56 +42,63 @@ Depending on the available hardware, you may need to adjust the following settin
3742
- Whether repositories should be deleted after they have been evaluated. This significantly reduces the amount of required free space on your drive (around 100GB should be enough).
3843

3944
> [!WARNING]
40-
> The entire set of repositories considered by our evaluation requires about 600 GBs of free space on our drive, if `clean-repositories` is set to `false`.
45+
> The entire set of repositories considered by our evaluation requires about 600 GBs of free space on our drive, if `clean-repositories` is set to `false`.
4146
4247
> [!NOTE]
4348
> Every change in the configuration must be followed by rebuilding the Docker image.
4449
45-
4650
### Building the Docker image
47-
The reproduction package is meant to be run in the Docker image that can be built using the provided Dockerfile.
51+
52+
The reproduction package is meant to be run in the Docker image that can be built using the provided Dockerfile.
4853

4954
#### Linux
55+
5056
On Linux, you can execute the provided `build.sh` script to build the Docker image.
5157

5258
> **Note:** The build process may take a while. (~5 minutes)
5359
5460
> **Note:** The build process may require sudo privileges.
5561
56-
```shell
62+
```shell
5763
./build.sh
5864
```
5965

6066
#### Other OS
61-
On other machines, you may call Docker directly.
67+
68+
On other machines, you may call Docker directly.
6269
In this case, you have to provide a USER_ID and GROUP_ID for the user in the Docker container:
70+
6371
```bash
6472
# For example, under Linux, both variables are set as follows:
6573
# USER_ID=$(id -u ${SUDO_USER:-$(whoami)})
6674
# GROUP_ID=$(id -g ${SUDO_USER:-$(whoami)})
6775

6876
docker build --network=host --build-arg USER_ID=$USER_ID --build-arg GROUP_ID=$GROUP_ID -t mpatch-reproduction .
6977
```
70-
Ideally, the `USER_ID` and `GROUP_ID` match the ids of the user running the command (not root!).
78+
79+
Ideally, the `USER_ID` and `GROUP_ID` match the ids of the user running the command (not root!).
7180
Under Windows, you may provide any suitable id (e.g., `1000` for both)
7281

73-
```shell
82+
```shell
7483
docker build --network=host --build-arg USER_ID=1000 --build-arg GROUP_ID=1000 -t mpatch-reproduction .
75-
```
76-
84+
```
7785

7886
### Verifying the correct installation
79-
Once the building of the Docker image has completed, you can verify its correct installation.
87+
88+
Once the building of the Docker image has completed, you can verify its correct installation.
8089
By default, the verification will be executed within the [evaluation-workdir](evaluation-workdir) directory.
8190

8291
#### Starting the verification
83-
On Linux, you can execute the provided `execute.sh` script with the `verification` argument:
92+
93+
On Linux, you can execute the provided `execute.sh` script with the `verification` argument:
94+
8495
```shell
8596
./execute.sh verification
8697
```
8798

88-
On other machines, you may start a Docker container from the Docker image with the following command:
89-
```bash
99+
On other machines, you may start a Docker container from the Docker image with the following command:
100+
101+
```bash
90102
# Depending on your OS, you may have to change how the first path to evaluation-workdir is defined
91103
docker run --rm -v "./evaluation-workdir/":"/home/user/evaluation-workdir" mpatch-reproduction verification
92104
```
@@ -95,12 +107,14 @@ docker run --rm -v "./evaluation-workdir/":"/home/user/evaluation-workdir" mpatc
95107
> Depending on your hardware, the verification should require 5-30 minutes.
96108
97109
#### Verification in a custom directory
110+
98111
> [!NOTE]
99-
> You may provide any directory as first argument for `-v`, either by altering the `execute.sh` script or changing the command above.
100-
> The `evaluation-workdir` is where the evaluation stores all its data while processing the repositories and evaluating patchers.
101-
> The results will also be saved to this directory, once the evaluation or verification finishes.
102-
103-
For example, your may start the evaluation with
112+
> You may provide any directory as first argument for `-v`, either by altering the `execute.sh` script or changing the command above.
113+
> The `evaluation-workdir` is where the evaluation stores all its data while processing the repositories and evaluating patchers.
114+
> The results will also be saved to this directory, once the evaluation or verification finishes.
115+
116+
For example, your may start the evaluation with
117+
104118
```shell
105119
docker run --rm -v "/home/YOUR_USERNAME/ICSE-reproduction/":"/home/user/evaluation-workdir" mpatch-reproduction verification
106120
```
@@ -110,9 +124,9 @@ docker run --rm -v "./evaluation-workdir/":"/home/user/evaluation-workdir" mpatc
110124
> [!NOTE]
111125
> If you executed the evaluation in a custom directory, all mentioned files will be located there.
112126
127+
The verification should begin with output that looks similar to the following screenshot:
113128

114-
The verification should begin with output that looks similar to the following screenshot:
115-
```shell
129+
```shell
116130
2025-08-21 14:36:30 [main] org.variantsync.evaluation.PatcherEvaluationMainKt.main()
117131
INFO: Starting experiment initialization.
118132
2025-08-21 14:36:30 [main] org.variantsync.evaluation.execution.EvalUtilsKt.createOrLoadSamples()
@@ -136,11 +150,13 @@ INFO: Considering a total of 85 cherry-picks for repetition 1
136150
INFO: cloning https://github.com/tensorflow/serving.git into /home/user/evaluation-workdir/REPOS/tensorflow_serving
137151
...
138152
```
139-
The output shows that the dataset used for verification contains one repository for each project language. The projects are cloned into the `evaluation-workdir`.
153+
154+
The output shows that the dataset used for verification contains one repository for each project language. The projects are cloned into the `evaluation-workdir`.
140155
Once a project has been cloned, the patchers are evaluated on the cherry picks (i.e., patches) that have been found for that repository.
141156

142157
The verification should complete with the following output:
143-
```shell
158+
159+
```shell
144160
Latexmk: All targets (metrics-verification.pdf) are up-to-date
145161

146162
++++++++++++++++++++++++++++++++++++
@@ -150,10 +166,8 @@ Latexmk: All targets (metrics-verification.pdf) are up-to-date
150166
The result table can be found under evaluation-workdir/metrics-verification.pdf
151167
```
152168

153-
After all repositories have been considered, the result analysis is executed.
154-
The raw results can be found in the `evaluation-workdir/results` directory.
155-
156-
169+
After all repositories have been considered, the result analysis is executed.
170+
The raw results can be found in the `evaluation-workdir/results` directory.
157171

158172
In addition, the script generates a PDF file with a result table similar to the one presented in our paper.
159173
This table can be found under `evaluation-workdir/metrics-verification.pdf`.
@@ -164,16 +178,19 @@ It should look similar to this:
164178
> The verification results shown are based on only a tiny portion of our dataset and are therefore not representative.
165179
166180
# Starting the reproduction
167-
Once you have verified the correct installation, you can start the reproduction similar to how you started the verification.
181+
182+
Once you have verified the correct installation, you can start the reproduction similar to how you started the verification.
168183
You may also change the working directory to a custom directory as described for the verification.
169184

170-
On Linux, you can execute the provided `execute.sh` script with the `reproduction` argument:
185+
On Linux, you can execute the provided `execute.sh` script with the `reproduction` argument:
186+
171187
```shell
172188
./execute.sh reproduction
173189
```
174190

175-
On other machines, you may start a Docker container from the Docker image with the following command:
176-
```bash
191+
On other machines, you may start a Docker container from the Docker image with the following command:
192+
193+
```bash
177194
# Depending on your OS, you may have to change how the first path to evaluation-workdir is defined
178195
docker run --rm -v "./evaluation-workdir/":"/home/user/evaluation-workdir" mpatch-reproduction reproduction
179196
```
@@ -182,26 +199,26 @@ docker run --rm -v "./evaluation-workdir/":"/home/user/evaluation-workdir" mpatc
182199
> The results of the reproduction will be stored in the same manner as the results of the verification.
183200
184201
> [!NOTE]
185-
> Our evaluation processes large amounts of data.
186-
> The main bottleneck is not the available CPU but the speed of the drive in which the `evaluation-workdir` is located.
187-
> Depending on your hardware, the full reproduction may require a very long time. The expected runtime are 5-10 days, but the reproduction may also require several weeks if the drive is too slow.
188-
189-
202+
> Our evaluation processes large amounts of data.
203+
> The main bottleneck is not the available CPU but the speed of the drive in which the `evaluation-workdir` is located.
204+
> Depending on your hardware, the full reproduction may require a very long time. The expected runtime are 5-10 days, but the reproduction may also require several weeks if the drive is too slow.
190205
191206
## Troubleshooting
192207

193208
### 'Got permission denied while trying to connect to the Docker daemon socket'
209+
194210
`Problem:` This is a common problem under Linux, if the user trying to execute Docker commands does not have the permissions to do so.
195211

196212
`Fix:` You can fix this problem by either following the [post-installation instructions](https://docs.docker.com/engine/install/linux-postinstall/), or by executing the scripts in the replication package with elevated permissions (i.e., `sudo`).
197213

198214
### 'Unable to find image 'mpatch-reproduction:latest' locally'
215+
199216
`Problem:` The Docker container could not be found. This either means that the name of the container that was built does not fit the name of the container that is being executed (this only happens if you changed the provided scripts), or that the Docker container was not built yet.
200217

201218
`Fix:` Follow the instructions described above in the section `Build the Docker Container`.
202219

203220
### Failed to load class "org.slf4j.impl.StaticLoggerBinder"
221+
204222
`Problem:` An operation within the initialization phase of the logger library we use (tinylog) failed.
205223

206224
`Fix:` Please ignore this warning. Tinylog will fall back onto a default implementation (`Defaulting to no-operation (NOP) logger implementation`) and logging will work as expected.
207-

0 commit comments

Comments
 (0)