Skip to content

Commit 03bc85a

Browse files
committed
updated configs
1 parent dac631b commit 03bc85a

2 files changed

Lines changed: 27 additions & 45 deletions

File tree

.github/workflows/update-contributors.yml

Lines changed: 13 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -18,30 +18,31 @@ jobs:
1818
with:
1919
token: ${{ secrets.GITHUB_TOKEN }}
2020

21-
- name: Fetch contributors and update Hall of Fame & README
21+
- name: Update Contributors in HALL_OF_FAME.md and README.md
2222
run: |
23-
# Fetch all contributors (excluding bots)
2423
CONTRIBUTORS=$(curl -s "https://api.github.com/repos/admirerr/DSA-Collection/contributors?per_page=100" \
2524
| jq -r '.[] | select(.type != "Bot") | [.login, .avatar_url, .html_url, .contributions] | @tsv' \
2625
| sort -k4,4nr)
2726
28-
# --- Build HTML blocks for Hall of Fame ---
29-
TABLE=$(echo "$CONTRIBUTORS" | awk -F'\t' '{printf "<a href=\"%s\" style=\"text-decoration:none; margin:10px;\"><img src=\"%s\" width=\"80\" height=\"80\" style=\"border-radius:50%%;\"><br>%s</a>\n", $3, $2, $1}')
27+
# Build Hall of Fame table with small avatars and handle below
28+
TABLE=$(echo "$CONTRIBUTORS" | awk -F'\t' '{printf "| <div align=\"center\"><img src=\"%s\" width=\"50\" height=\"50\"/><br>[%s](%s)</div> | %s |\n", $2, $1, $3, $4}')
3029
31-
# --- Build avatars row for README ---
32-
AVATARS="<div align=\"center\">$(echo "$CONTRIBUTORS" | awk -F'\t' '{printf "[<img src=\"%s\" width=\"80\" height=\"80\" style=\"border-radius:50%%;\" alt=\"%s\"/>](%s) ", $2, $1, $3}'))</div>"
30+
# Build avatars row for README (small images)
31+
AVATARS=$(echo "$CONTRIBUTORS" | awk -F'\t' '{printf "[<img src=\"%s\" width=\"50\" height=\"50\" alt=\"%s\"/>](%s) ", $2, $1, $3}')
3332
34-
# --- Update Hall of Fame ---
33+
# ---- Update Hall of Fame ----
3534
awk -v table="$TABLE" '
36-
/<!-- Contributors will be automatically updated by GitHub Actions -->/ {
35+
/Contributor \| Contributions/ {
3736
print;
37+
print "|-------------|---------------|";
3838
print table;
39-
next;
39+
in_block=1; next;
4040
}
41+
in_block && /^\|/ {next}
4142
{print}
4243
' HALL_OF_FAME.md > temp && mv temp HALL_OF_FAME.md
4344
44-
# --- Update README ---
45+
# ---- Update README ----
4546
awk -v avatars="$AVATARS" '
4647
/<!-- CONTRIBUTORS START -->/ {
4748
print;
@@ -55,18 +56,15 @@ jobs:
5556
5657
- name: Update Implementation Counts
5758
run: |
58-
# Update total implementations
5959
sed -i 's/| 🎯 \*\*Total Implementations\*\* | [0-9]\+ |/| 🎯 **Total Implementations** | 22 |/' HALL_OF_FAME.md
60-
61-
# Update per-language implementations
6260
sed -i '/### Python/{n;s/- Implementations: [0-9]\+/- Implementations: 6/}' HALL_OF_FAME.md
6361
sed -i '/### C++/{n;s/- Implementations: [0-9]\+/- Implementations: 4/}' HALL_OF_FAME.md
6462
sed -i '/### Java/{n;s/- Implementations: [0-9]\+/- Implementations: 12/}' HALL_OF_FAME.md
6563
66-
- name: Commit and Push Changes
64+
- name: Commit changes
6765
run: |
6866
git config --local user.email "actions@github.com"
6967
git config --local user.name "GitHub Actions"
7068
git add HALL_OF_FAME.md README.md
7169
git commit -m "Update contributors and implementations" || echo "No changes to commit"
72-
git push
70+
git push

HALL_OF_FAME.md

Lines changed: 14 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,19 @@
1-
# 🌟 DSA Collection Hall of Fame
2-
3-
We are incredibly grateful to all our amazing contributors who make this repository a valuable resource for learning DSA! Your contributions of implementations, improvements, and insights help the community grow every day. Keep up the fantastic work! 🚀
4-
5-
<div align="center">
6-
7-
<!-- Contributors will be automatically updated by GitHub Actions -->
8-
<!-- Example: -->
9-
<a href="https://github.com/admirerr" style="text-decoration:none; margin:10px;">
10-
<img src="https://avatars.githubusercontent.com/u/79766263?v=4" width="80" height="80" style="border-radius:50%;"><br>
11-
admirerr
12-
</a>
13-
<a href="https://github.com/Vivek13121" style="text-decoration:none; margin:10px;">
14-
<img src="https://avatars.githubusercontent.com/u/171781925?v=4" width="80" height="80" style="border-radius:50%;"><br>
15-
Vivek13121
16-
</a>
17-
<a href="https://github.com/actions-user" style="text-decoration:none; margin:10px;">
18-
<img src="https://avatars.githubusercontent.com/u/65916846?v=4" width="80" height="80" style="border-radius:50%;"><br>
19-
actions-user
20-
</a>
21-
22-
</div>
1+
# 🌟 Hall of Fame
2+
3+
| Contributor | Contributions |
4+
|-------------|---------------|
5+
| <img src="https://avatars.githubusercontent.com/u/79766263?v=4" width="50" height="50"/> [admirerr](https://github.com/admirerr) | 82 |
6+
| <img src="https://avatars.githubusercontent.com/u/171781925?v=4" width="50" height="50"/> [Vivek13121](https://github.com/Vivek13121) | 3 |
7+
| <img src="https://avatars.githubusercontent.com/u/65916846?v=4" width="50" height="50"/> [actions-user](https://github.com/actions-user) | 3 |
8+
| <img src="https://avatars.githubusercontent.com/u/222441895?v=4" width="50" height="50"/> [adesh2756](https://github.com/adesh2756) | 3 |
9+
| <img src="https://avatars.githubusercontent.com/u/72244992?v=4" width="50" height="50"/> [Anujmishra2005](https://github.com/Anujmishra2005) | 1 |
10+
| <img src="https://avatars.githubusercontent.com/u/41038007?v=4" width="50" height="50"/> [djashan](https://github.com/djashan) | 1 |
11+
| <img src="https://avatars.githubusercontent.com/u/197562965?v=4" width="50" height="50"/> [ramanuj-droid](https://github.com/ramanuj-droid) | 1 |
12+
| <img src="https://avatars.githubusercontent.com/u/109014091?v=4" width="50" height="50"/> [ruturajjadhav07](https://github.com/ruturajjadhav07) | 1 |
13+
| <img src="https://avatars.githubusercontent.com/u/103595490?v=4" width="50" height="50"/> [sujanrupu](https://github.com/sujanrupu) | 1 |
2314

2415
---
2516

26-
| 🎯 **Total Implementations** | 22 |
2717

2818
---
2919

@@ -34,10 +24,4 @@ We are incredibly grateful to all our amazing contributors who make this reposit
3424
- Implementations: 4
3525

3626
### Java
37-
- Implementations: 12
38-
39-
---
40-
41-
*Last updated: October 2025*
42-
43-
Thank you to everyone for your contributions and support in building a thriving DSA community! 🎉
27+
- Implementations: 12

0 commit comments

Comments
 (0)