Skip to content

Commit

Permalink
Small fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
MSt-10 committed Mar 12, 2024
1 parent 4ab46a4 commit 9c08a08
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@
## Overview

This GitHub Action is designed to reverse-engineer a project's source code into a Palladio Component Model (PCM) and upload the PCM as an artifact named `retriever`.
In addition to that further useful information and measurements on the project are gathered and collected in a report.
This action is intended to be used to analyze projects in a reusable and automatic way to document and to gather insights.
In addition to that further useful information and measurements on the project are gathered and collected in a markdown report.
This action is intended to be used to analyze projects in a reusable and automatic manner.

## How It Works

Expand All @@ -16,18 +16,18 @@ The action performs several steps to generate the PCM and the report:
2. **Create Temporary Directory:**
Prepares a workspace for the retriever's output and intermediate files of the report.
3. **Gather Retriever Information:**
Collects and records information about the Retriever tool's version and execution date.
Collects and records information about the retriever version and execution date.
4. **Gather Git Repository Information:**
Retrieves and logs details about the Git repository, including the URL, branch, and latest commit.
This is done for all repositories in case a multi repository project is analyzed.
Retrieves and logs details about the git repository, including the URL, branch, and latest commit.
This is done for all repositories of the analyzed project in case it is a multi repository project.
5. **Gather System Information:**
Installs `neofetch` to fetch and log detailed system information of the GitHub runner that executes the action.
6. **Perform Code Analysis:**
Uses `cloc` to analyze the source code, providing a summary of languages used, lines of code, and comments.
Uses `cloc` to analyze the source code, providing a summary of languages used, lines of code and comments.
7. **Execution Timing:**
This step executes the Retriever and measures the runtime of the reverse engineering process.
Depending on the input value of the parameter `benchmark`, the runtime is either measured using `time` or benchmarked using `hyperfine`.
The benchmark performs 3 warmup cycles after which 10 runs are performed to measure the descriptive statistics of the runtime.
Depending on the input value of the parameter `benchmark`, the runtime is either simply measured using `time` or benchmarked using `hyperfine`.
In case of the benchmark, 3 warmup cycles are performed after which 10 runs are executed to measure the descriptive statistics of the runtime.
8. **Combine and Clean Up Files:**
Aggregates all collected information into a single `README.md` file and cleans up intermediate files.
9. **Upload Analysis Results:**
Expand All @@ -42,7 +42,7 @@ The action requires the following inputs:
| source_path | Required | The project location to reverse-engineer. | Root directory |
| rules* | Required | A comma-separated list of rules for reverse-engineering. | Maven and Spring |
| rules_path | Optional | Location of additional project-specific rules. | Root directory |
| benchmark | Optional | Whether to use Hyperfine for benchmarking the retriever's execution. | false |
| benchmark | Optional | Whether to use hyperfine for benchmarking the retriever's execution. | false |

*The following `rules` are currently supported:
- Maven Project Object Model: `org.palladiosimulator.retriever.extraction.rules.maven`
Expand All @@ -51,12 +51,12 @@ The action requires the following inputs:

## Output

The output artifact, named `retriever`, contains the Palladio Component Model (PCM) and the markdown report `README.md` containing the gathered information and measurements.
The output artifact, named `retriever` contains the Palladio Component Model (PCM) and the markdown report `README.md` containing the gathered information and measurements.

## Example Usage

This is a sample workflow that uses the retriever action.
Add this `.yml` file to the workflow folder `./github/workflows/` of your GitHub.
Add this `.yml` file to the workflow folder `./github/workflows/` of your GitHub project:

```yaml
name: Reverse Engineering
Expand All @@ -80,5 +80,5 @@ jobs:
rules: "org.palladiosimulator.retriever.extraction.rules.maven,org.palladiosimulator.retriever.extraction.rules.spring"
```
This example checks out a project and runs the Retriever action on the `src/my_project` directory with the specified rule.
Benchmarking is enabled to provide detailed information about the execution time.
This example checks out the repository and runs the retriever action on the `src/my_project` directory with the specified rules.
Here, benchmarking is enabled to provide detailed information about the execution time.

0 comments on commit 9c08a08

Please sign in to comment.