Giter Site home page Giter Site logo

nolan7512 / snk Goto Github PK

View Code? Open in Web Editor NEW

This project forked from sutil/snk

0.0 0.0 0.0 695 KB

🟩⬜ Generates a snake game from a github user contributions graph and output a screen capture as animated svg or gif

Home Page: https://platane.github.io/snk

Shell 0.09% JavaScript 0.14% TypeScript 99.58% Dockerfile 0.20%

snk's Introduction

snk

English

This project is an version of Platane/snk project!

What it does?

You can generate an svg or gif file that is an snake eating your contributions on Github, and you can put it in your profile.

Snake animation

What is different from the original project?

  • The generated background image is semitransparent (Nice for dark or light themes).
  • You can chose the snake color!

How can use it?

  • put the snake README file.

    ![snake animation](https://github.com/<seu user name>/<seu user name>/blob/output/github-contribution-grid-snake2.svg)
  • Create a file .github/workflows/snake.yml for github actions generate the snake.

  • Copy the content below into the .yml file.
    If you want, Change the snake_color.

name: Generate snake game

on:
  schedule: # execute every 12 hours
    - cron: "* */12 * * *"
  workflow_dispatch:

jobs:
  build:
    name: Jobs to update datas
    runs-on: ubuntu-latest
    steps:
      # Snake Animation
      - uses: Sutil/snk@master
        id: snake-gif
        with:
          github_user_name: ${{ github.repository_owner }}
          svg_out_path: dist/github-contribution-grid-snake2.svg
          snake_color: 'blue'

      - uses: crazy-max/[email protected]
        with:
          target_branch: output
          build_dir: dist
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
  

Every 12 hours your the svg or gif will be updated!

Português

Este projeto é uma versão do projeto Platane/snk!

O que esse projeto faz?

Você pode gerar um svg ou gif que é uma cobrinha comendo suas contribuições no Github e colocar no seu perfil!

Snake animation

O que tem de diferente do projeto original?

  • O README está escrito em português! o/
  • O background da imagem gerada é semi-transparente.
  • Você pode escolher a cor da cobrinha!

Como eu posso usar?

  • Crie um repositório com o mesmo nome do seu perfil no github. No meu caso, eu criei um repo com o nome Sutil (https://github.com/Sutil). Neste exemplo o repo ficará com o endereço https://github.com/Sutil/Sutil.

  • Dentro deste projeto crie um arquivo README.md O Conteúdo deste arquivo será mostrado no seu Perfil do github. Veja o exemplo do meu perfil.

  • Coloque a cobrinha neste arquivo de README.

    a) Para fazer isso, coloque a url da imagem que será gerada.

    ![snake animation](https://github.com/<seu user name>/<seu user name>/blob/output/github-contribution-grid-snake2.svg)

    b) crie um github actions dentro do seu repo. Para isso crie um arquivo .github/workflows/snake.yml.

    coloque o conteúdo abaixo dentro do arquivo. Se desejar, troque a cor snake_color.

name: Generate snake game

on:
  schedule: # execute every 12 hours
    - cron: "* */12 * * *"
  workflow_dispatch:

jobs:
  build:
    name: Jobs to update datas
    runs-on: ubuntu-latest
    steps:
      # Snake Animation
      - uses: Sutil/snk@master
        id: snake-gif
        with:
          github_user_name: ${{ github.repository_owner }}
          svg_out_path: dist/github-contribution-grid-snake2.svg
          snake_color: 'blue'

      - uses: crazy-max/[email protected]
        with:
          target_branch: output
          build_dir: dist
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
  

A cada 12 horas seu perfil será atualizado!

snk's People

Contributors

platane avatar sutil avatar nolan7512 avatar fz6m avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.