{"id":22177240,"url":"https://github.com/watzon/goshot","last_synced_at":"2025-10-24T09:35:30.233Z","repository":{"id":263555066,"uuid":"888918075","full_name":"watzon/goshot","owner":"watzon","description":"🎨 Create beautiful code screenshots with customizable styles ","archived":false,"fork":false,"pushed_at":"2024-12-27T21:28:34.000Z","size":11150,"stargazers_count":145,"open_issues_count":0,"forks_count":5,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-29T14:12:37.993Z","etag":null,"topics":["carbon-alternative","cli-tool","code-snippets","developer-tools","documentation-tools","golang","image-generation","presentation-tools","screenshots","syntax-highlighting"],"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/watzon.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":"2024-11-15T08:58:35.000Z","updated_at":"2025-03-27T06:46:07.000Z","dependencies_parsed_at":"2024-12-07T01:27:19.971Z","dependency_job_id":"58379c06-0327-4fc5-bc9d-bae78f2510ea","html_url":"https://github.com/watzon/goshot","commit_stats":null,"previous_names":["watzon/goshot"],"tags_count":20,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/watzon%2Fgoshot","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/watzon%2Fgoshot/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/watzon%2Fgoshot/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/watzon%2Fgoshot/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/watzon","download_url":"https://codeload.github.com/watzon/goshot/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247353747,"owners_count":20925329,"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":["carbon-alternative","cli-tool","code-snippets","developer-tools","documentation-tools","golang","image-generation","presentation-tools","screenshots","syntax-highlighting"],"created_at":"2024-12-02T08:26:33.115Z","updated_at":"2025-10-24T09:35:25.190Z","avatar_url":"https://github.com/watzon.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Goshot\n\n\u003ca href=\"https://pkg.go.dev/github.com/watzon/goshot\"\u003e\u003cimg src=\"https://pkg.go.dev/badge/github.com/watzon/goshot.svg\" alt=\"Go Reference\"\u003e\u003c/a\u003e\n\u003ca href=\"https://goreportcard.com/report/github.com/watzon/goshot\"\u003e\u003cimg src=\"https://goreportcard.com/badge/github.com/watzon/goshot\" alt=\"Go Report Card\"\u003e\u003c/a\u003e\n\u003ca href=\"LICENSE\"\u003e\u003cimg src=\"https://img.shields.io/github/license/watzon/goshot\" alt=\"License\"\u003e\u003c/a\u003e\n\nGoshot is a powerful Go library and CLI tool for creating beautiful screenshots of code and terminal command output with customizable window chrome, syntax highlighting, and backgrounds. Similar to [Carbon](https://carbon.now.sh) and [Silicon](https://github.com/Aloxaf/Silicon), Goshot allows you to create stunning visual representations of your code snippets for documentation, presentations, or social media sharing.\n\n\u003cdiv align=\"center\"\u003e\n    \u003cimg src=\".github/example.png\"\u003e\n\u003c/div\u003e\n\n## ✨ Features\n\n- 🎨 Beautiful syntax highlighting with multiple themes\n- 🖼 Customizable window chrome (macOS, Windows, Linux styles)\n- 🌈 Various background options (solid colors, gradients, images)\n- 🔤 Custom font support\n- 📏 Adjustable padding and margins\n- 💾 Multiple export formats (PNG, JPEG)\n- 🛠 Both CLI and library interfaces\n- 🚀 Command execution support\n\n## Quick Start\n\n### Installation\n\n\u003e [!NOTE]  \n\u003e The CLI is a work in progress, but should be more or less functional.\n\n```bash\n# Install the CLI tool\ngo install github.com/watzon/goshot/cmd/goshot@latest\n\n# Install the library\ngo get github.com/watzon/goshot\n```\n\n#### Package Managers\n\n##### Arch Linux (AUR)\n\n```bash\n# Using yay\nyay -S goshot-bin\n\n# Using paru\nparu -S goshot-bin\n```\n\n##### Ubuntu/Debian\n\n```bash\n# Add the PPA\nsudo add-apt-repository ppa:watzon/goshot\nsudo apt update\n\n# Install goshot\nsudo apt install goshot\n```\n\n[![Packaging status](https://repology.org/badge/vertical-allrepos/goshot.svg)](https://repology.org/project/goshot/versions)\n\n### Basic Usage\n\n```go\npackage main\n\nimport (\n    \"image/color\"\n    \"log\"\n\n    \"github.com/watzon/goshot/background\"\n    \"github.com/watzon/goshot/chrome\"\n    \"github.com/watzon/goshot/render\"\n)\n\nfunc main() {\n    // Create a new canvas with macOS chrome and gradient background\n    canvas := render.NewCanvas().\n        SetChrome(chrome.NewMacChrome(chrome.WithTitle(\"Hello World\"))).\n        SetBackground(\n            background.NewGradientBackground(\n                background.LinearGradient,\n                background.GradientStop{Color: color.RGBA{R: 26, G: 27, B: 38, A: 255}, Position: 0},\n                background.GradientStop{Color: color.RGBA{R: 40, G: 42, B: 54, A: 255}, Position: 1},\n            ).\n                SetAngle(45).\n                SetPadding(40).\n                SetCornerRadius(8).\n                SetShadow(\n                    background.NewShadow().\n                        SetOffset(0, 3).\n                        SetBlur(20).\n                        SetSpread(8).\n                        SetColor(color.RGBA{R: 0, G: 0, B: 0, A: 200}),\n                ),\n        ).\n        SetCodeStyle(\u0026render.CodeStyle{\n            Language:        \"go\",\n            Theme:           \"dracula\",\n            TabWidth:        4,\n            ShowLineNumbers: true,\n        })\n\n    // Render code to file\n    code := `func main() {\n        fmt.Println(\"Hello, World!\")\n    }`\n    \n    img, err := canvas.RenderToImage(code)\n    if err != nil {\n        log.Fatal(err)\n    }\n    \n    if err := render.SaveAsPNG(img, \"code.png\"); err != nil {\n        log.Fatal(err)\n    }\n}\n```\n\n## Documentation\n\nFor detailed documentation, examples, and guides, please visit our [Wiki](https://github.com/watzon/goshot/wiki):\n\n- [Installation Guide](https://github.com/watzon/goshot/wiki/Installation) - Detailed installation instructions\n- [Library Usage](https://github.com/watzon/goshot/wiki/Library-Usage) - Library documentation and examples\n- [Configuration](https://github.com/watzon/goshot/wiki/Configuration) - Configuration options and customization\n- [Contributing](https://github.com/watzon/goshot/wiki/Contributing) - Guidelines for contributing\n\n## Star History\n\n[![Star History Chart](https://api.star-history.com/svg?repos=watzon/goshot\u0026type=Date)](https://star-history.com/#watzon/goshot\u0026Date)\n\n## License\n\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwatzon%2Fgoshot","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fwatzon%2Fgoshot","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fwatzon%2Fgoshot/lists"}