feat: Just task to create CONTRIBUTORS.md file #23

Manually merged
awiteb merged 4 commits from awiteb/contributors-file into master 2024-07-20 15:12:50 +02:00 AGit
Showing only changes of commit bb66f4d71b - Show all commits

View file

@ -5,7 +5,7 @@
# - just (Of course) <https://github.com/casey/just>
# - cargo (For the build and tests) <https://doc.rust-lang.org/cargo/getting-started/installation.html>
set shell := ["/usr/bin/bash", "-c"]
set shell := ["/usr/bin/env", "bash", "-c"]
JUST_EXECUTABLE := "just -u -f " + justfile()
header := "Available tasks:\n"
@ -36,7 +36,7 @@ run:
# Generate the contributors list from the git log
# then add it to the CONTRIBUTORS file
contributors:
#! /bin/env bash
#! /usr/bin/env bash
maintainers="- Awiteb <a@4rs.nl>\n- Amjad Alsharafi <me@amjad.alsharafi.dev>"
reviewers=`git log --pretty=format:"%b" | grep -i "Reviewed-by" | sed 's/Reviewed-by: /- /' | sort | uniq`
reporters=`git log --pretty=format:"%b" | grep -i "Reported-by" | sed 's/Reported-by: /- /' | sort | uniq`
@ -47,9 +47,9 @@ contributors:
contributors_count=`echo -e "${maintainers}\n${authors}\n${co_authors}\n${reviewers}\n${reporters}\n${suggesters}\n${helpers}" | grep -Ev '^$' | sort | uniq | wc -l`
footer="Oxidetalis Homeserver currently has ${contributors_count} contributors!\n\nInterested in becoming a contributor? Read the [CONTRIBUTING.md](CONTRIBUTING.md) file to get started."
file="# Contributors\nA heartfelt thank you to all the contributors who have helped make Oxidetalis Homeserver better. Below is a list of the contributors who have played a crucial role in the development and improvement of the Oxidetalis Homeserver.\n\n## Maintainers\nMaintainers are responsible for overseeing the project, keeping it up to date, and ensuring it runs smoothly.\n\n${maintainers}"
file="# Contributors\nA heartfelt thank you to all the contributors who have helped make Oxidetalis Homeserver better. Below is a list of the contributors who have played a crucial role in the development and improvement of Oxidetalis Homeserver.\n\n## Maintainers\nMaintainers are responsible for overseeing Oxidetalis, keeping it up to date, and ensuring it runs smoothly.\n\n${maintainers}"
if [ -n "$authors" ]; then
file="${file}\n\n## Code Authors\nCode authors have written the code for the project.\n\n${authors}"
file="${file}\n\n## Code Authors\nCode authors have written the code for Oxidetalis.\n\n${authors}"
fi
if [ -n "$co_authors" ]; then
file="${file}\n${co_authors}"
@ -58,10 +58,10 @@ contributors:
file="${file}\n\n## Reviewers\nCode reviewers have reviewed the code and provided feedback, suggestions, and improvements.\n\n${reviewers}"
fi
if [ -n "$reporters" ]; then
file="${file}\n\n## Bug Reporters\nBug reporters have identified and reported bugs in the project, helping to improve its quality.\n\n${reporters}"
file="${file}\n\n## Bug Reporters\nBug reporters have identified and reported bugs in Oxidetalis, helping to improve its quality.\n\n${reporters}"
fi
if [ -n "$suggesters" ]; then
file="${file}\n\n## Feature Suggesters\nFeature suggesters have proposed new features to enhance the project.\n\n${suggesters}"
file="${file}\n\n## Feature Suggesters\nFeature suggesters have proposed new features to enhance Oxidetalis.\n\n${suggesters}"
fi
if [ -n "$helpers" ]; then
file="${file}\n\n## Helpers\nHelpers have contributed in various ways that do not involve writing code, such as providing feedback, suggestions, and improvements.\n\n${helpers}"