gomodifytags
brew install gomodifytags
v1.17.0
BSD-3-Clause
Go tool to modify struct field tags
12
30-day installs · #8218
27
90-day · #8910
141
365-day · #8279
2.4k
★ GitHub stars · updated 1y ago
Build dependencies
GitHub topics
go
golang
structs
tags
tool
Links
- https://github.com/fatih/gomodifytags
- GitHub: fatih/gomodifytags
- Brew formula source: Formula/g/gomodifytags.rb
Raw metadata
{
"aliases": [],
"alternatives": [],
"build_dependencies": [
"go"
],
"categories": [],
"caveats": null,
"conflicts_with": [],
"dependencies": [],
"deprecated": 0,
"deprecation_reason": null,
"desc": "Go tool to modify struct field tags",
"disable_reason": null,
"disabled": 0,
"enrichment_fetched_at": "2026-06-20T23:38:18+00:00",
"first_seen": "2026-06-20T23:34:18+00:00",
"full_name": "gomodifytags",
"github_default_branch": "main",
"github_last_commit_at": "2025-04-23T14:27:48Z",
"github_readme_excerpt": "# gomodifytags [](https://github.com/fatih/gomodifytags/actions)\n\nGo tool to modify/update field tags in structs. `gomodifytags` makes it easy to\nupdate, add or delete the tags in a struct field. You can easily add new tags,\nupdate existing tags (such as appending a new key, i.e: `db`, `xml`, etc..) or\nremove existing tags. It also allows you to add and remove tag options. It\u0027s\nintended to be used by an editor, but also has modes to run it from the\nterminal. Read the usage section below for more information.\n\n\n\n\n# Install\n\n```bash\ngo install github.com/fatih/gomodifytags@latest\n```\n\n# Supported editors\n\n* [vim-go](https://github.com/fatih/vim-go) with `:GoAddTags` and `:GoRemoveTags`\n* [go-plus (atom)](https://github.com/joefitzgerald/go-plus) with commands `golang:add-tags` and `golang:remove-tags`\n* [vscode-go](https://github.com/golang/vscode-go) with commands `Go: Add Tags` and `Go: Remove Tags`\n* [A (Acme)](https://github.com/davidrjenni/A) with commands `addtags` and `rmtags`\n* [emacs-go-tag](https://github.com/brantou/emacs-go-tag) with commands `go-tag-add` and `go-tag-remove`\n* [TextMate2](https://github.com/vigo/textmate2-gomodifytags)\n\n# Usage\n\n`gomodifytags` has multiple ways to modify a tag. Let\u0027s start with an example package:\n\n```go\npackage main\n\ntype Server struct {\n\tName string\n\tPort int\n\tEnableLogs bool\n\tBaseDomain string\n\tCredentials struct {\n\t\tUsername string\n\t\tPassword string\n\t}\n}\n```\n\nWe have to first pass a file. For that we can use the `-file` flag:\n\n```sh\n$ gomodifytags -file demo.go\n-line, -offset, -struct or -all is not passed\n```\n\nWhat are these? There are four different ways of defining **which** field tags\nto change:\n\n* `-struct`: This accepts the struct name. i.e: `-struct Server`. The name\n should be a valid type name. The `-struct` flag ",
"github_repo": "fatih/gomodifytags",
"github_stars": 2387,
"github_topics": [
"go",
"golang",
"structs",
"tags",
"tool"
],
"homepage": "https://github.com/fatih/gomodifytags",
"homepage_og_description": null,
"homepage_og_image": null,
"homepage_title": null,
"installs_30d": 12,
"installs_365d": 141,
"installs_90d": 27,
"keg_only": 0,
"keg_only_reason": null,
"last_seen": "2026-06-20T23:34:18+00:00",
"license": "BSD-3-Clause",
"llm_generated_at": null,
"llm_model": null,
"name": "gomodifytags",
"oldnames": [],
"one_liner": null,
"optional_dependencies": [],
"rank_30d": 8218,
"rank_365d": 8279,
"rank_90d": 8910,
"raw_hash": "f2ed962658dc38f6",
"recommended_dependencies": [],
"revision": 0,
"ruby_source_path": "Formula/g/gomodifytags.rb",
"tap": "homebrew/core",
"test_dependencies": [],
"uses_from_macos": [],
"version_head": "HEAD",
"version_stable": "1.17.0",
"versioned_formulae": [],
"why_use_this": null
}