Skip to content

Commit

Permalink
chore: check coverage image with dive
Browse files Browse the repository at this point in the history
closes #11
  • Loading branch information
ialejandro committed Aug 15, 2024
1 parent 275fec7 commit a2fb960
Show file tree
Hide file tree
Showing 4 changed files with 73 additions and 2 deletions.
29 changes: 29 additions & 0 deletions .github/workflows/check-changes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,12 @@ jobs:
with:
fetch-depth: 0

- name: Set up QEMU
uses: docker/setup-qemu-action@v3

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

- name: Get current tag
id: current_release
run: |
Expand Down Expand Up @@ -98,6 +104,29 @@ jobs:
echo -e "$body" > pr-output.log
- name: "Build and push Docker image"
uses: docker/build-push-action@v6
with:
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache-new,mode=max
context: .
platforms: linux/amd64
push: false
tags: kafka-cruise-control-${{ env.GITHUB_JOB }}

- name: Show changes
if: steps.check_changes.outputs.release_changed == 'true'
run: |
# install dive
mkdir dive && cd dive
wget https://github.com/wagoodman/dive/releases/download/v${{ vars.DIVE_VERSION }}/dive_${{ vars.DIVE_VERSION }}_linux_amd64.tar.gz
tar xzvf dive_${{ vars.DIVE_VERSION }}_linux_amd64.tar.gz
cd ..
# dive
echo -e "\n## Dive output\n" >> pr-output.log
./dive/dive -t kafka-cruise-control-${{ env.GITHUB_JOB }} >> pr-output.log
- name: Create PR changes
if: steps.check_changes.outputs.release_changed == 'true'
uses: peter-evans/create-pull-request@v6
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
pr-output.log
dive
dive/*
42 changes: 41 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1 +1,41 @@
TODO
# How to contribute to Cruise Control

This document provides guidelines for contributing to the *Cruise Control* project.

## How can I contribute?

### Did you find a bug?

* **Ensure the bug has not already been reported** by searching on GitHub under [Issues](https://github.com/devops-ia/kafka-cruise-control/issues).
* If you cannot find an open issue addressing the problem, [open a new one](https://github.com/devops-ia/kafka-cruise-control/issues/new). Include a **title and clear description**, as much relevant information as possible, and a **code sample** or an **executable test case** demonstrating the unexpected behavior.
* Use the relevant bug report templates to create the issue, if available.

### Do you intend to add a new feature or change an existing one?

* Please discuss first ([open an issue](https://github.com/devops-ia/kafka-cruise-control/issues)) before starting any significant pull request (e.g., implementing features, refactoring code) to avoid spending time on something that might not be merged.
* Adhere to the project's coding conventions (indentation, accurate comments, etc.) and any other requirements (such as test coverage, documentation).

## Styleguides

### YAML Styleguide

All YAML files must adhere to the following style guide:

* Indentation: Use 2 spaces for indentation.
* No trailing spaces.
* Use hyphens for list items.
* Use camelCase for key names.
* Ensure there are no syntax errors.

Additional rules:

* Always use double quotes for strings.
* Keep lines to a maximum of 80 characters.
* Ensure proper alignment of nested elements.

### Git Commit Messages

* Use the present tense ("Add feature" not "Added feature").
* Use the imperative mood ("Move cursor to..." not "Moves cursor to...").
* Limit the first line to 72 characters or less.
* Reference issues and pull requests liberally after the first line.
2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
MIT License

Copyright (c) 2023 DevOps Solutions
Copyright (c) 2024 DevOps Solutions

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
Expand Down

0 comments on commit a2fb960

Please sign in to comment.