{"id":25878487,"url":"https://github.com/killerasus/gocalc","last_synced_at":"2026-05-08T22:34:02.882Z","repository":{"id":44753456,"uuid":"441404541","full_name":"killerasus/GoCalc","owner":"killerasus","description":"The purpose of this Calculator is to practice unit testing in Go","archived":false,"fork":false,"pushed_at":"2024-06-13T01:26:24.000Z","size":102,"stargazers_count":0,"open_issues_count":3,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-02T12:38:08.327Z","etag":null,"topics":["codecov","github-actions","go","golang","tdd","unit-testing"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/killerasus.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":"2021-12-24T07:59:01.000Z","updated_at":"2024-06-13T01:26:27.000Z","dependencies_parsed_at":"2025-03-02T12:33:34.250Z","dependency_job_id":"264a6268-36de-45d2-8f13-3fadf02a516e","html_url":"https://github.com/killerasus/GoCalc","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/killerasus/GoCalc","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/killerasus%2FGoCalc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/killerasus%2FGoCalc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/killerasus%2FGoCalc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/killerasus%2FGoCalc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/killerasus","download_url":"https://codeload.github.com/killerasus/GoCalc/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/killerasus%2FGoCalc/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32800275,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-08T08:22:46.396Z","status":"ssl_error","status_checked_at":"2026-05-08T08:22:45.650Z","response_time":54,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: 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":["codecov","github-actions","go","golang","tdd","unit-testing"],"created_at":"2025-03-02T12:33:25.292Z","updated_at":"2026-05-08T22:34:02.868Z","avatar_url":"https://github.com/killerasus.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Go RPN Calculator\n\nAn over-engineered RPN calculator built to practice unit testing, error reporting, GUI development, and CLI in Go.\n\n[![Build Status](https://app.travis-ci.com/killerasus/GoCalc.svg?branch=master)](https://app.travis-ci.com/github/killerasus/GoCalc)\n\n## CLI\n\nTo run the command line interface of the Go RPN Calculator, go to folder `cli` and run `go run cli.go` or `go build`.\n\nCLI interface supports flags. See implemented flags and usage with `-h` or `-help`.\n\nFor example: CLI supports expression evaluation. The result is stacked.\n\n![Using CLI for evaluating expressions](img/cli.png \"Example using -eval option to evaluate RPN expression\")\n\n## GUI\n\n### Fyne\n\nA GUI version of the calculator made with the free and open source [fyne](https://fyne.io/) toolkit.\n\n![Calculator GUI in Fyne](img/fynegui.png \"GUI implemented using the Fyne toolkit\")\n\nCompile with `go build -o gorpn.exe gui/fyne/main.go`. Remember that you will have to provide a GNU C++ compiler (in Windows you can use [MSYS2](https://www.msys2.org/) to provide GCC).\n\nCalculator icons created by [Freepik - Flaticon](https://www.flaticon.com/free-icons/calculator).\n## Testing\n\nRun tests with `go test ./stack ./calculator ./operations -v` command in the root directory.\n\n## Class Diagram\n\n```mermaid\nclassDiagram\n\n    IStack \u003c|-- Stack\n    Calculator *-- Stack\n    Calculator --\u003e Operations\n\n    class IStack {\n        \u003c\u003cinterface\u003e\u003e\n        +Push(float64)\n        +Pop() float64\n        +Peek() float64\n        +Peeki(int i) (float64, bool)\n        +Size() int\n        +IsEmpty() bool\n    }\n\n    class Stack  {\n        -float64[]\n    }\n\n    class Calculator {\n        -Stack stack\n        +Size() int\n        +Push(float64 a) void\n        +Peek() (float64, bool)\n        +Peeki(i int) (float64, bool)\n        +Pop() (float64, bool)\n        +Add() (float64, bool)\n        +Subtract() (float64, bool)\n        +Multiplication() (float64, bool)\n        +Division() (float64, bool)\n        +Evaluate(string e) (v float64, ok bool)\n    }\n\n    class Operations {\n        \u003c\u003cnamespace\u003e\u003e\n        +Add(float64 a, float64 b) float64\n        +Subtract(float64 a, float64 b) float64\n        +Multiply(float64 a, float64 b) float64\n        +Divide(float64 a, float64 b) float64\n        +UnaryNegative(float64 a) float64\n        +Root(float64 a, float64 root) float64\n        +SquareRoot(float64 a) float64\n    }\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkillerasus%2Fgocalc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkillerasus%2Fgocalc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkillerasus%2Fgocalc/lists"}