{"id":17882364,"url":"https://github.com/mgjules/deckr","last_synced_at":"2025-03-22T12:32:25.389Z","repository":{"id":57696186,"uuid":"491249758","full_name":"mgjules/deckr","owner":"mgjules","description":"Deckr provides a REST/gRPC API to simulate a deck of cards.","archived":false,"fork":false,"pushed_at":"2023-08-28T19:23:17.000Z","size":491,"stargazers_count":5,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-18T11:11:28.791Z","etag":null,"topics":["card-game","deckofcards","go","golang","grpc","rest-api"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mgjules.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2022-05-11T19:39:10.000Z","updated_at":"2024-01-12T18:30:30.000Z","dependencies_parsed_at":"2024-06-20T12:59:57.353Z","dependency_job_id":"c9a4522c-848c-45c8-a643-beadc7886b64","html_url":"https://github.com/mgjules/deckr","commit_stats":null,"previous_names":[],"tags_count":9,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mgjules%2Fdeckr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mgjules%2Fdeckr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mgjules%2Fdeckr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mgjules%2Fdeckr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mgjules","download_url":"https://codeload.github.com/mgjules/deckr/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244959444,"owners_count":20538625,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["card-game","deckofcards","go","golang","grpc","rest-api"],"created_at":"2024-10-28T12:52:04.623Z","updated_at":"2025-03-22T12:32:25.043Z","avatar_url":"https://github.com/mgjules.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# deckr 🃏\n\n[![Go Doc](https://img.shields.io/badge/godoc-reference-blue.svg?style=for-the-badge)](https://godoc.org/github.com/mgjules/deckr)\n[![Conventional Commits](https://img.shields.io/badge/Conventional%20Commits-1.0.0-yellow.svg?style=for-the-badge)](https://conventionalcommits.org)\n[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg?style=for-the-badge)](LICENSE)\n\nDeckr provides a REST/gRPC API to simulate a deck of cards.\n\n\n## Contents\n\n- [deckr 🃏](#deckr-)\n  - [Contents](#contents)\n  - [Requirements](#requirements)\n  - [Mage Targets](#mage-targets)\n    - [Example](#example)\n      - [Generate stubs from proto files](#generate-stubs-from-proto-files)\n      - [Run tests with race detector](#run-tests-with-race-detector)\n      - [Build deckr for MacOS M1](#build-deckr-for-macos-m1)\n  - [Install](#install)\n  - [Usage](#usage)\n    - [REST/gRPC API server](#restgrpc-api-server)\n  - [REST API documentation](#rest-api-documentation)\n  - [License](#license)\n\n## Requirements\n\n- [Go 1.18+](https://golang.org/doc/install)\n- [Mage](https://github.com/magefile/mage) - replacement for Makefile in Go.\n    \n    ```shell\n    $ go install github.com/magefile/mage@latest\n    ```\n\n- [Golangci-lint](https://github.com/golangci/golangci-lint) - Fast Go linters runner.\n      \n    ```shell\n    $ go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest\n    ```\n    \n- [Ginkgo](https://github.com/onsi/ginkgo) - Expressive testing framework.\n        \n    ```shell\n    $ go install github.com/onsi/ginkgo/v2/ginkgo@latest\n    ```\n\n- [Buf](https://github.com/bufbuild/buf) - A new way of working with Protocol Buffers.\n\n   ```shell\n   $ go install github.com/bufbuild/buf/cmd/buf@latest\n   ```\n\n- [Protoc](https://developers.google.com/protocol-buffers) - Protocol Buffers compiler.\n\n   For installation instructions, see [Protocol Buffer Compiler Installation](https://grpc.io/docs/protoc-installation/).\n\n- [Protoc-gen-go](https://github.com/golang/protobuf/protoc-gen-go) - Go code generator for Protocol Buffers.\n  \n   ```shell\n   $ go install github.com/golang/protobuf/protoc-gen-go@latest\n   ```\n\n- [Protoc-gen-go-grpc](https://google.golang.org/grpc/cmd/protoc-gen-go-grpc) - Go code generator for gRPC.\n  \n   ```shell\n   $ go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@latest\n   ```\n    \n- [Docker](https://www.docker.com) - Containerization.\n\n## Mage Targets\n\n```shell\n$ mage -l\n```\n\n```\nTargets:\n  build:all           Builds for all supported popular OS/Arch\n  build:linuxAmd64    Builds for Linux 64bit\n  build:linuxArm64    Builds for Linux ARM 64bit\n  build:macOSAmd64    Builds for MacOS 64bit\n  build:macOSArm64    Builds for MacOS M1\n  build:winAmd64      Builds for Windows 64bit\n  lint                Run golangci linters\n  proto               Generate stubs from proto files\n  test                Run tests\n  testRace            Run tests with race detector\n  tidy                Run go mod tidy\n```\n\n### Example\n\n#### Generate stubs from proto files\n\n```shell\n$ mage -v proto\n```\n\n#### Run tests with race detector\n\n```shell\n$ mage -v testRace\n```\n\n#### Build deckr for MacOS M1\n\n```shell\n$ mage -v build:macOSArm64\n```\n\n## Install\n\n- You can install using the [latest released binary](https://github.com/mgjules/deckr/releases/latest).\n\n- **OR** using Go:\n\n    ```shell\n    $ go install github.com/mgjules/deckr@latest\n    ```\n\n- **OR** bulding from source:\n\n    Example (MacOS M1):\n\n    ```shell\n    $ mage -v build:macOSArm64\n    ```\n\n## Usage\n\n```shell\n$ deckr --help\n```\n\n```\nNAME:\n   deckr - A REST/gRPC API for playing with a deck of cards\n\nUSAGE:\n   deckr [global options] command [command options] [arguments...]\n\nDESCRIPTION:\n   Deckr exposes a REST/gRPC API for playing with a deck of cards of your choice.\n\nAUTHOR:\n   Michaël Giovanni Jules \u003cjulesmichaelgiovanni@gmail.com\u003e\n\nCOMMANDS:\n   serve       Starts the REST/gRPC API server.\n   version, v  Shows the version\n   help, h     Shows a list of commands or help for one command\n\nGLOBAL OPTIONS:\n   --help, -h  show help (default: false)\n\nCOPYRIGHT:\n   (c) 2022 Michaël Giovanni Jules\n```\n\n### REST/gRPC API server\n\n```shell\n$ deckr serve --help\n```\n\n```\nNAME:\n   deckr serve - Starts the REST/gRPC API server.\n\nUSAGE:\n   deckr serve [command options] [arguments...]\n\nOPTIONS:\n   --debug              whether running in PROD or DEBUG mode (default: false) [$DECKR_DEBUG]\n   --server-host value  HOST of server (default: \"localhost\") [$DECKR_SERVER_HOST]\n   --server-port value  PORT of server (default: 9000) [$DECKR_SERVER_PORT]\n   --storage-uri value  URI of storage (default: \"inmemory://\") [$DECKR_STORAGE_URI]\n   --help, -h           show help (default: false)\n```\n\n## REST API documentation\n\nThe REST API documentation is generated using Swag and is available at `/swagger/index.html`.\n\n## License\n\nDeckr is Apache 2.0 licensed.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmgjules%2Fdeckr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmgjules%2Fdeckr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmgjules%2Fdeckr/lists"}