{"id":18277067,"url":"https://github.com/kelvinleandro/jogo-do-bicho","last_synced_at":"2026-04-02T01:02:50.852Z","repository":{"id":253869532,"uuid":"842223169","full_name":"kelvinleandro/jogo-do-bicho","owner":"kelvinleandro","description":"Jogo do Bicho básico implementado com socket.io (Flask) e React (Next.js) para a interface","archived":false,"fork":false,"pushed_at":"2024-08-19T23:28:14.000Z","size":138,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-01-03T14:35:14.508Z","etag":null,"topics":["flask","flask-socketio","javascript","jogo-do-bicho","nextjs","nextjs14","python","python3","react","reactjs","shadcn-ui","socket-io","typescript","websocket"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kelvinleandro.png","metadata":{"files":{"readme":"README.en.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-08-13T23:27:34.000Z","updated_at":"2024-08-19T23:42:00.000Z","dependencies_parsed_at":"2024-08-20T04:30:44.265Z","dependency_job_id":null,"html_url":"https://github.com/kelvinleandro/jogo-do-bicho","commit_stats":null,"previous_names":["kelvinleandro/jogo-do-bicho"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/kelvinleandro/jogo-do-bicho","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kelvinleandro%2Fjogo-do-bicho","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kelvinleandro%2Fjogo-do-bicho/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kelvinleandro%2Fjogo-do-bicho/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kelvinleandro%2Fjogo-do-bicho/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kelvinleandro","download_url":"https://codeload.github.com/kelvinleandro/jogo-do-bicho/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kelvinleandro%2Fjogo-do-bicho/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31293631,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-01T21:15:39.731Z","status":"ssl_error","status_checked_at":"2026-04-01T21:15:34.046Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["flask","flask-socketio","javascript","jogo-do-bicho","nextjs","nextjs14","python","python3","react","reactjs","shadcn-ui","socket-io","typescript","websocket"],"created_at":"2024-11-05T12:18:02.672Z","updated_at":"2026-04-02T01:02:50.801Z","avatar_url":"https://github.com/kelvinleandro.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# Jogo do Bicho\n\nThis is a Jogo do Bicho (Animal Game) application, developed using React (Next.js) with TypeScript and Shadcn UI for the interface. Real-time communication between players and the server is handled using Socket.IO. The server is built with Python using Flask-SocketIO.\n\n## Features\n\n- **Animal Selection:** Players can choose from a set of animal cards to place their bets.\n- **Synchronized Betting:** All players can place their bets, and the server provides feedback once everyone has made their choices.\n- **Real-Time Communication:** The application uses Socket.IO for real-time communication between the client and the server.\n\n## Project Structure\n\n```plaintext\njogo-do-bicho/\n├── client/                 # Client source code (Next.js)\n│   ├── src/\n│   │   ├── app/\n│   │   │   ├── game/       # Game page\n│   │   │   └── ...\n│   │   ├── components/     # Reusable UI components\n│   │   ├── constants/      # Project constants (e.g., list of animals)\n│   │   ├── lib/            # Helper functions\n│   │   └── utils/          # Socket.IO client configuration\n│   ├── public/             # Public files (e.g., favicon, icons)\n│   ├── tailwind.config.ts  # Tailwind CSS configuration\n│   ├── package.json        # Client project dependencies and scripts\n│   └── ...                 # Other configuration files\n├── server/                 # Server source code (Flask-SocketIO)\n│   ├── animals.py          # Project constants (e.g., list of animals)\n│   ├── app.py              # Flask-SocketIO server setup\n│   ├── requirements.txt    # Server project dependencies\n└── ...\n```\n\n## Configuration\n\n### Server\n\nThe Flask-SocketIO server can be configured using the `.env` file. Environment variables include:\n\n- `PORT`: Defines the port on which the server will run.\n- `MAX_CLIENTS`: Defines the maximum number of connected players.\n\n### Client\n\nThe Next.js client can be configured using the `.env.local` file. Environment variables include:\n\n- `PORT`: Define the port on which the server is running (in case it is running on the same machine).\n- `SERVER_URL`: Defines the Flask-SocketIO server URL for deployments.\n\n## Running the Project\n\n### Server\n\n1. Navigate to the `server` directory.\n\n   ```bash\n   cd server\n   ```\n\n2. (Optional) Create a virtual environment and activate it:\n\n   ```bash\n   python3 -m venv .venv\n   source .venv/bin/activate # for Linux\n   .\\.venv\\Scripts\\activate # for Windows\n   ```\n\n3. Install Python dependencies:\n\n   ```bash\n   pip install -r requirements.txt\n   ```\n\n4. Start the server:\n\n   ```bash\n   python app.py\n   ```\n\n### Client\n\n1. Navigate to the `client` directory.\n\n   ```bash\n   cd client\n   ```\n\n2. Install Node.js dependencies:\n\n   ```bash\n   npm install\n   ```\n\n3. Start the client:\n\n   ```bash\n   npm run dev\n   ```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkelvinleandro%2Fjogo-do-bicho","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkelvinleandro%2Fjogo-do-bicho","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkelvinleandro%2Fjogo-do-bicho/lists"}