Skip to content

Front- and Back-End for badgestore.dev allowing you to create, store and update badges

License

Notifications You must be signed in to change notification settings

Sh1nku/badgestore

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Badgestore

Lines of Code badge

This is the front-end and back-end for badgestore.dev. The website allows you to create badges, and update them.

There is support for badges in the following formats:

Note: This project is not affiliated with any of the above services/libraries.
The front-end is written in Svelte and the back-end is written using Axum.

How to use

Creating a badge

Using the website

To create a badge, go to badgestore.dev and click on the Generate button.

Using the API

Take a look at api.badgestore.dev

Updating a badge

Using the API

Take a look at api.badgestore.dev

Using the github action

Take a look at Sh1nku/badgestore-update-badge-action

Examples

A github action for updating the lines of code of the repo, and updating a badge given a secret called BADGESTORE_RW_KEY with the value read_key:write_key

name: Count lines of code for the project, and upload to the badge store

on:
  push:
    branches:
      - 'master'

jobs:
  count-loc-and-upload:
    runs-on: ubuntu-latest
    permissions:
      contents: read
      packages: write

    steps:
      - uses: actions/checkout@v3
      - id: loc
        name: Count lines of code
        uses: Sh1nku/count-loc-action@v1
        with:
          excluded: "*.json,*.svg,*.md"
      - uses: Sh1nku/badgestore-update-badge-action@v1
        name: Update badge
        id: badge
        with:
          right-label: ${{ steps.loc.outputs.Total_code }}
          read-write-key: ${{ secrets.BADGESTORE_RW_KEY }}
      - uses: koki-develop/hub-purge-action@v1