[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7592P6RPSZTAZTF5TEQSTD6":3,"skill-same:01M7592P6RPSZTAZTF5TEQSTD6":72},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":37,"commitSha":38,"skillDirectory":39,"forksCount":40,"repositoryHtmlUrl":41,"repositoryHomepageUrl":6,"ownerHtmlUrl":42,"ownerBlogUrl":6,"ownerDescription":43,"updatedAt":44,"install":45,"resources":57},"01M7592P6RPSZTAZTF5TEQSTD6","golang-safety",null,"Defensive Golang coding to prevent panics, silent data corruption, and subtle runtime bugs. Use when encountering nil panics, append aliasing, map concurrent access, float comparison pitfalls, or zero-value design questions. Also use when reviewing code for nil-safety, numeric conversion overflow, resource lifecycle issues (defer in loops), or defensive copying of slices and maps.","davidcoachdev\u002Fdcfiles","davidcoachdev","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F69812733?v=4","01M758C4BR16TAV1N47W319E9V","David H. Caycedo Blum.","01M758C4CCZA2ZYGA0BGMXCDRH",1,"MIT","https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fgolang-safety\u002FSKILL.md",[],[],"2026-11-12 13:55:43",false,"---\nname: golang-safety\ndescription: \"Defensive Golang coding to prevent panics, silent data corruption, and subtle runtime bugs. Use when encountering nil panics, append aliasing, map concurrent access, float comparison pitfalls, or zero-value design questions. Also use when reviewing code for nil-safety, numeric conversion overflow, resource lifecycle issues (defer in loops), or defensive copying of slices and maps.\"\nuser-invocable: true\nlicense: MIT\ncompatibility: Designed for OpenCode or similar AI coding agents, and for projects using Golang.\nmetadata:\n  author: gentleman-programming\n  version: \"1.2.1\"\n  openclaw:\n    emoji: \"🛡\"\n    homepage: https:\u002F\u002Fgithub.com\u002Fgentleman-programming\n    requires:\n      bins:\n        - go\n    install: []\nallowed-tools: Read Edit Write Glob Grep Bash(go:*) Bash(golangci-lint:*) Bash(git:*) Agent\n---\n\n**Persona:** You are a defensive Go engineer. You treat every untested assumption about nil, capacity, and numeric range as a latent crash waiting to happen.\n\n# Go Safety: Correctness & Defensive Coding\n\nPrevents programmer mistakes — bugs, panics, and silent data corruption in normal (non-adversarial) code. Security handles attackers; safety handles ourselves.\n\n## Best Practices Summary\n\n1. **Prefer generics over `any`** when the type set is known — compiler catches mismatches instead of runtime panics\n2. **Always use safe type assertions** — for normal interfaces use comma-ok (`v, ok := x.(T)`); for reflection in Go 1.25+ prefer `reflect.TypeAssert[T](value)` over `value.Interface().(T)`.\n3. **Typed nil pointer in an interface is not `== nil`** — the type descriptor makes it non-nil\n4. **Writing to a nil map panics** — always initialize before use\n5. **`append` may reuse the backing array** — both slices share memory if capacity allows, silently corrupting each other\n6. **Return defensive copies** from exported functions — otherwise callers mutate your internals\n7. **`defer` runs at function exit, not loop iteration** — extract loop body to a function\n8. **Integer conversions truncate silently** — `int64` to `int32` wraps without error\n9. **Float arithmetic is not exact** — use epsilon comparison or `math\u002Fbig`\n10. **Design useful zero values** — nil map fields panic on first write; use lazy init\n11. **Use `sync.Once` for lazy init** — guarantees exactly-once even under concurrency\n\n## Nil Safety\n\nNil-related panics are the most common crash in Go.\n\n### The nil interface trap\n\nInterfaces store (type, value). An interface is `nil` only when both are nil. Returning a typed nil pointer sets the type descriptor, making it non-nil:\n\n```go\n\u002F\u002F ✗ Dangerous — interface{type: *MyHandler, value: nil} is not == nil\nfunc getHandler() http.Handler {\n    var h *MyHandler \u002F\u002F nil pointer\n    if !enabled {\n        return h \u002F\u002F interface{type: *MyHandler, value: nil} != nil\n    }\n    return h\n}\n\n\u002F\u002F ✓ Good — return nil explicitly\nfunc getHandler() http.Handler {\n    if !enabled {\n        return nil \u002F\u002F interface{type: nil, value: nil} == nil\n    }\n    return &MyHandler{}\n}\n```\n\n### Nil map, slice, and channel behavior\n\n| Type    | Index into nil | Write to nil   | Len\u002FCap of nil | Range over nil |\n| ------- | -------------- | -------------- | -------------- | -------------- |\n| Map     | Zero value     | **panic**      | 0              | 0 iterations   |\n| Slice   | **panic**      | **panic**      | 0              | 0 iterations   |\n| Channel | Blocks forever | Blocks forever | 0              | Blocks forever |\n\n```go\n\u002F\u002F ✗ Bad — nil map panics on write\nvar m map[string]int\nm[\"key\"] = 1\n\n\u002F\u002F ✓ Good — initialize or lazy-init in methods\nm := make(map[string]int)\n\nfunc (r *Registry) Add(name string, val int) {\n    if r.items == nil { r.items = make(map[string]int) }\n    r.items[name] = val\n}\n```\n\nSee **[Nil Safety Deep Dive](.\u002Freferences\u002Fnil-safety.md)** for nil receivers, nil in generics, and nil interface performance.\n\n## Slice & Map Safety\n\n### Slice aliasing — the append trap\n\n`append` reuses the backing array if capacity allows. Both slices then share memory:\n\n```go\n\u002F\u002F ✗ Dangerous — a and b share backing array\na := make([]int, 3, 5)\nb := append(a, 4)\nb[0] = 99 \u002F\u002F also modifies a[0]\n\n\u002F\u002F ✓ Good — full slice expression forces new allocation\nb := append(a[:len(a):len(a)], 4)\n```\n\n### Map concurrent access\n\nMaps MUST NOT be accessed concurrently — → see `golang-concurrency` for sync primitives.\n\nSee **[Slice and Map Deep Dive](.\u002Freferences\u002Fslice-map-safety.md)** for range pitfalls, subslice memory retention, and `slices.Clone`\u002F`maps.Clone`.\n\n## Numeric Safety\n\n### Implicit type conversions truncate silently\n\n```go\n\u002F\u002F ✗ Bad — silently wraps around if val > math.MaxInt32 (3B becomes -1.29B)\nvar val int64 = 3_000_000_000\ni32 := int32(val) \u002F\u002F -1294967296 (silent wraparound)\n\n\u002F\u002F ✓ Good — check before converting\nif val > math.MaxInt32 || val \u003C math.MinInt32 {\n    return fmt.Errorf(\"value %d overflows int32\", val)\n}\ni32 := int32(val)\n```\n\n### Float comparison\n\n```go\n\u002F\u002F ✗ Bad — floating point arithmetic is not exact\nvar a, b, c float64 = 0.1, 0.2, 0.3\na+b == c \u002F\u002F false\n\n\u002F\u002F ✓ Good — use epsilon comparison\nconst epsilon = 1e-9\nmath.Abs((a+b)-c) \u003C epsilon \u002F\u002F true\n```\n\n### Division by zero\n\nInteger division by zero panics. Float division by zero produces `+Inf`, `-Inf`, or `NaN`.\n\n```go\nfunc avg(total, count int) (int, error) {\n    if count == 0 {\n        return 0, errors.New(\"division by zero\")\n    }\n    return total \u002F count, nil\n}\n```\n\nFor integer overflow as a security vulnerability, see the `golang-security` skill section.\n\n## Resource Safety\n\n### defer in loops — resource accumulation\n\n`defer` runs at _function_ exit, not loop iteration. Resources accumulate until the function returns:\n\n```go\n\u002F\u002F ✗ Bad — all files stay open until function returns\nfor _, path := range paths {\n    f, _ := os.Open(path)\n    defer f.Close() \u002F\u002F deferred until function exits\n    process(f)\n}\n\n\u002F\u002F ✓ Good — extract to function so defer runs per iteration\nfor _, path := range paths {\n    if err := processOne(path); err != nil { return err }\n}\nfunc processOne(path string) error {\n    f, err := os.Open(path)\n    if err != nil { return err }\n    defer f.Close()\n    return process(f)\n}\n```\n\n### Goroutine leaks\n\n→ See `golang-concurrency` for goroutine lifecycle and leak prevention.\n\n## Immutability & Defensive Copying\n\nExported functions returning slices\u002Fmaps SHOULD return defensive copies.\n\n### Protecting struct internals\n\n```go\n\u002F\u002F ✗ Bad — exported slice field, anyone can mutate\ntype Config struct {\n    Hosts []string\n}\n\n\u002F\u002F ✓ Good — unexported field with accessor returning a copy\ntype Config struct {\n    hosts []string\n}\n\nfunc (c *Config) Hosts() []string {\n    return slices.Clone(c.hosts)\n}\n```\n\n## Initialization Safety\n\n### Zero-value design\n\nDesign types so `var x MyType` is safe — prevents \"forgot to initialize\" bugs:\n\n```go\nvar mu sync.Mutex   \u002F\u002F ✓ usable at zero value\nvar buf bytes.Buffer \u002F\u002F ✓ usable at zero value\n\n\u002F\u002F ✗ Bad — nil map panics on write\ntype Cache struct { data map[string]any }\n```\n\n### sync.Once for lazy initialization\n\n```go\ntype DB struct {\n    once sync.Once\n    conn *sql.DB\n}\n\nfunc (db *DB) connection() *sql.DB {\n    db.once.Do(func() {\n        db.conn, _ = sql.Open(\"postgres\", connStr)\n    })\n    return db.conn\n}\n```\n\n### init() function pitfalls\n\n→ See `golang-design-patterns` for why init() should be avoided in favor of explicit constructors.\n\n## Enforce with Linters\n\nMany safety pitfalls are caught automatically by linters: `errcheck`, `forcetypeassert`, `nilerr`, `govet`, `staticcheck`. See the `golang-lint` skill for configuration and usage.\n\n### Go 1.25+ reflection type assertions\n\nFor reflection code, prefer `reflect.TypeAssert[T]` over `value.Interface().(T)`.\n\n```go\nv := reflect.ValueOf(x)\nif s, ok := reflect.TypeAssert[string](v); ok {\n    use(s)\n}\n```\n\n## Cross-References\n\n- → See `golang-concurrency` skill for concurrent access patterns and sync primitives\n- → See `golang-data-structures` skill for slice\u002Fmap internals, capacity growth, and container\u002F packages\n- → See `golang-error-handling` skill for nil error interface trap\n- → See `golang-security` skill for security-relevant safety issues (memory safety, integer overflow)\n- → See `golang-troubleshooting` skill for debugging panics and race conditions\n\n## Common Mistakes\n\n| Mistake | Fix |\n| --- | --- |\n| Bare type assertion `v := x.(T)` | Panics on type mismatch, crashing the program. Use `v, ok := x.(T)` to handle gracefully |\n| Returning typed nil in interface function | Interface holds (type, nil) which is != nil. Return untyped `nil` for the nil case |\n| Writing to a nil map | Nil maps have no backing storage — write panics. Initialize with `make(map[K]V)` or lazy-init |\n| Assuming `append` always copies | If capacity allows, both slices share the backing array. Use `s[:len(s):len(s)]` to force a copy |\n| `defer` in a loop | `defer` runs at function exit, not loop iteration — resources accumulate. Extract body to a separate function |\n| `int64` to `int32` without bounds check | Values wrap silently (3B → -1.29B). Check against `math.MaxInt32`\u002F`math.MinInt32` first |\n| Comparing floats with `==` | IEEE 754 representation is not exact (`0.1+0.2 != 0.3`). Use `math.Abs(a-b) \u003C epsilon` |\n| Integer division without zero check | Integer division by zero panics. Guard with `if divisor == 0` before dividing |\n| Returning internal slice\u002Fmap reference | Callers can mutate your struct's internals through the shared backing array. Return a defensive copy |\n| Multiple `init()` with ordering assumptions | `init()` execution order across files is unspecified. → See `golang-design-patterns` — use explicit constructors |\n| Blocking forever on nil channel | Nil channels block on both send and receive. Always initialize before use |\n\n## Cross-References\n\n- → See `golang-continuous-integration` skill for automated AI-driven code review in CI using these guidelines\n","**Persona:** You are a defensive Go engineer. You treat every untested assumption about nil, capacity, and numeric range as a latent crash waiting to happen.\n\n# Go Safety: Correctness & Defensive Coding\n\nPrevents programmer mistakes — bugs, panics, and silent data corruption in normal (non-adversarial) code. Security handles attackers; safety handles ourselves.\n\n## Best Practices Summary\n\n1. **Prefer generics over `any`** when the type set is known — compiler catches mismatches instead of runtime panics\n2. **Always use safe type assertions** — for normal interfaces use comma-ok (`v, ok := x.(T)`); for reflection in Go 1.25+ prefer `reflect.TypeAssert[T](value)` over `value.Interface().(T)`.\n3. **Typed nil pointer in an interface is not `== nil`** — the type descriptor makes it non-nil\n4. **Writing to a nil map panics** — always initialize before use\n5. **`append` may reuse the backing array** — both slices share memory if capacity allows, silently corrupting each other\n6. **Return defensive copies** from exported functions — otherwise callers mutate your internals\n7. **`defer` runs at function exit, not loop iteration** — extract loop body to a function\n8. **Integer conversions truncate silently** — `int64` to `int32` wraps without error\n9. **Float arithmetic is not exact** — use epsilon comparison or `math\u002Fbig`\n10. **Design useful zero values** — nil map fields panic on first write; use lazy init\n11. **Use `sync.Once` for lazy init** — guarantees exactly-once even under concurrency\n\n## Nil Safety\n\nNil-related panics are the most common crash in Go.\n\n### The nil interface trap\n\nInterfaces store (type, value). An interface is `nil` only when both are nil. Returning a typed nil pointer sets the type descriptor, making it non-nil:\n\n```go\n\u002F\u002F ✗ Dangerous — interface{type: *MyHandler, value: nil} is not == nil\nfunc getHandler() http.Handler {\n    var h *MyHandler \u002F\u002F nil pointer\n    if !enabled {\n        return h \u002F\u002F interface{type: *MyHandler, value: nil} != nil\n    }\n    return h\n}\n\n\u002F\u002F ✓ Good — return nil explicitly\nfunc getHandler() http.Handler {\n    if !enabled {\n        return nil \u002F\u002F interface{type: nil, value: nil} == nil\n    }\n    return &MyHandler{}\n}\n```\n\n### Nil map, slice, and channel behavior\n\n| Type    | Index into nil | Write to nil   | Len\u002FCap of nil | Range over nil |\n| ------- | -------------- | -------------- | -------------- | -------------- |\n| Map     | Zero value     | **panic**      | 0              | 0 iterations   |\n| Slice   | **panic**      | **panic**      | 0              | 0 iterations   |\n| Channel | Blocks forever | Blocks forever | 0              | Blocks forever |\n\n```go\n\u002F\u002F ✗ Bad — nil map panics on write\nvar m map[string]int\nm[\"key\"] = 1\n\n\u002F\u002F ✓ Good — initialize or lazy-init in methods\nm := make(map[string]int)\n\nfunc (r *Registry) Add(name string, val int) {\n    if r.items == nil { r.items = make(map[string]int) }\n    r.items[name] = val\n}\n```\n\nSee **[Nil Safety Deep Dive](.\u002Freferences\u002Fnil-safety.md)** for nil receivers, nil in generics, and nil interface performance.\n\n## Slice & Map Safety\n\n### Slice aliasing — the append trap\n\n`append` reuses the backing array if capacity allows. Both slices then share memory:\n\n```go\n\u002F\u002F ✗ Dangerous — a and b share backing array\na := make([]int, 3, 5)\nb := append(a, 4)\nb[0] = 99 \u002F\u002F also modifies a[0]\n\n\u002F\u002F ✓ Good — full slice expression forces new allocation\nb := append(a[:len(a):len(a)], 4)\n```\n\n### Map concurrent access\n\nMaps MUST NOT be accessed concurrently — → see `golang-concurrency` for sync primitives.\n\nSee **[Slice and Map Deep Dive](.\u002Freferences\u002Fslice-map-safety.md)** for range pitfalls, subslice memory retention, and `slices.Clone`\u002F`maps.Clone`.\n\n## Numeric Safety\n\n### Implicit type conversions truncate silently\n\n```go\n\u002F\u002F ✗ Bad — silently wraps around if val > math.MaxInt32 (3B becomes -1.29B)\nvar val int64 = 3_000_000_000\ni32 := int32(val) \u002F\u002F -1294967296 (silent wraparound)\n\n\u002F\u002F ✓ Good — check before converting\nif val > math.MaxInt32 || val \u003C math.MinInt32 {\n    return fmt.Errorf(\"value %d overflows int32\", val)\n}\ni32 := int32(val)\n```\n\n### Float comparison\n\n```go\n\u002F\u002F ✗ Bad — floating point arithmetic is not exact\nvar a, b, c float64 = 0.1, 0.2, 0.3\na+b == c \u002F\u002F false\n\n\u002F\u002F ✓ Good — use epsilon comparison\nconst epsilon = 1e-9\nmath.Abs((a+b)-c) \u003C epsilon \u002F\u002F true\n```\n\n### Division by zero\n\nInteger division by zero panics. Float division by zero produces `+Inf`, `-Inf`, or `NaN`.\n\n```go\nfunc avg(total, count int) (int, error) {\n    if count == 0 {\n        return 0, errors.New(\"division by zero\")\n    }\n    return total \u002F count, nil\n}\n```\n\nFor integer overflow as a security vulnerability, see the `golang-security` skill section.\n\n## Resource Safety\n\n### defer in loops — resource accumulation\n\n`defer` runs at _function_ exit, not loop iteration. Resources accumulate until the function returns:\n\n```go\n\u002F\u002F ✗ Bad — all files stay open until function returns\nfor _, path := range paths {\n    f, _ := os.Open(path)\n    defer f.Close() \u002F\u002F deferred until function exits\n    process(f)\n}\n\n\u002F\u002F ✓ Good — extract to function so defer runs per iteration\nfor _, path := range paths {\n    if err := processOne(path); err != nil { return err }\n}\nfunc processOne(path string) error {\n    f, err := os.Open(path)\n    if err != nil { return err }\n    defer f.Close()\n    return process(f)\n}\n```\n\n### Goroutine leaks\n\n→ See `golang-concurrency` for goroutine lifecycle and leak prevention.\n\n## Immutability & Defensive Copying\n\nExported functions returning slices\u002Fmaps SHOULD return defensive copies.\n\n### Protecting struct internals\n\n```go\n\u002F\u002F ✗ Bad — exported slice field, anyone can mutate\ntype Config struct {\n    Hosts []string\n}\n\n\u002F\u002F ✓ Good — unexported field with accessor returning a copy\ntype Config struct {\n    hosts []string\n}\n\nfunc (c *Config) Hosts() []string {\n    return slices.Clone(c.hosts)\n}\n```\n\n## Initialization Safety\n\n### Zero-value design\n\nDesign types so `var x MyType` is safe — prevents \"forgot to initialize\" bugs:\n\n```go\nvar mu sync.Mutex   \u002F\u002F ✓ usable at zero value\nvar buf bytes.Buffer \u002F\u002F ✓ usable at zero value\n\n\u002F\u002F ✗ Bad — nil map panics on write\ntype Cache struct { data map[string]any }\n```\n\n### sync.Once for lazy initialization\n\n```go\ntype DB struct {\n    once sync.Once\n    conn *sql.DB\n}\n\nfunc (db *DB) connection() *sql.DB {\n    db.once.Do(func() {\n        db.conn, _ = sql.Open(\"postgres\", connStr)\n    })\n    return db.conn\n}\n```\n\n### init() function pitfalls\n\n→ See `golang-design-patterns` for why init() should be avoided in favor of explicit constructors.\n\n## Enforce with Linters\n\nMany safety pitfalls are caught automatically by linters: `errcheck`, `forcetypeassert`, `nilerr`, `govet`, `staticcheck`. See the `golang-lint` skill for configuration and usage.\n\n### Go 1.25+ reflection type assertions\n\nFor reflection code, prefer `reflect.TypeAssert[T]` over `value.Interface().(T)`.\n\n```go\nv := reflect.ValueOf(x)\nif s, ok := reflect.TypeAssert[string](v); ok {\n    use(s)\n}\n```\n\n## Cross-References\n\n- → See `golang-concurrency` skill for concurrent access patterns and sync primitives\n- → See `golang-data-structures` skill for slice\u002Fmap internals, capacity growth, and container\u002F packages\n- → See `golang-error-handling` skill for nil error interface trap\n- → See `golang-security` skill for security-relevant safety issues (memory safety, integer overflow)\n- → See `golang-troubleshooting` skill for debugging panics and race conditions\n\n## Common Mistakes\n\n| Mistake | Fix |\n| --- | --- |\n| Bare type assertion `v := x.(T)` | Panics on type mismatch, crashing the program. Use `v, ok := x.(T)` to handle gracefully |\n| Returning typed nil in interface function | Interface holds (type, nil) which is != nil. Return untyped `nil` for the nil case |\n| Writing to a nil map | Nil maps have no backing storage — write panics. Initialize with `make(map[K]V)` or lazy-init |\n| Assuming `append` always copies | If capacity allows, both slices share the backing array. Use `s[:len(s):len(s)]` to force a copy |\n| `defer` in a loop | `defer` runs at function exit, not loop iteration — resources accumulate. Extract body to a separate function |\n| `int64` to `int32` without bounds check | Values wrap silently (3B → -1.29B). Check against `math.MaxInt32`\u002F`math.MinInt32` first |\n| Comparing floats with `==` | IEEE 754 representation is not exact (`0.1+0.2 != 0.3`). Use `math.Abs(a-b) \u003C epsilon` |\n| Integer division without zero check | Integer division by zero panics. Guard with `if divisor == 0` before dividing |\n| Returning internal slice\u002Fmap reference | Callers can mutate your struct's internals through the shared backing array. Return a defensive copy |\n| Multiple `init()` with ordering assumptions | `init()` execution order across files is unspecified. → See `golang-design-patterns` — use explicit constructors |\n| Blocking forever on nil channel | Nil channels block on both send and receive. Always initialize before use |\n\n## Cross-References\n\n- → See `golang-continuous-integration` skill for automated AI-driven code review in CI using these guidelines\n",{"name":5,"license":15,"metadata":24,"description":7,"allowed-tools":34,"compatibility":35,"user-invocable":36},{"author":25,"version":26,"openclaw":27},"gentleman-programming","1.2.1",{"emoji":28,"install":29,"homepage":30,"requires":31},"🛡",[],"https:\u002F\u002Fgithub.com\u002Fgentleman-programming",{"bins":32},[33],"go","Read Edit Write Glob Grep Bash(go:*) Bash(golangci-lint:*) Bash(git:*) Agent","Designed for OpenCode or similar AI coding agents, and for projects using Golang.",true,"main","5dc86f90a5cbe45db3acd917825461b3ed6937fb","config\u002F.config\u002Fopencode\u002Fskills\u002Fgolang-safety",0,"https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles","https:\u002F\u002Fgithub.com\u002Fdavidcoachdev","🌐 Apasionado por crear soluciones web escalables y eficientes. \r\n🧑‍🏫 Coach Dev.\r\n💻 Frontend Dev. \r\n🎚️Backend Dev.\r\n📊 Agile\u002FScrum.\r\n🚀100% remoto.","2026-08-26 07:28:05",{"source":8,"skillName":5,"commands":46,"prompt":56,"zipAvailable":36},[47,50,53],{"tool":48,"command":49},"npx","npx skills add davidcoachdev\u002Fdcfiles --skill golang-safety",{"tool":51,"command":52},"bunx","bunx skills add davidcoachdev\u002Fdcfiles --skill golang-safety",{"tool":54,"command":55},"pnpm","pnpm dlx skills add davidcoachdev\u002Fdcfiles --skill golang-safety","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fgolang-safety\u002FSKILL.md",[58,64,68],{"path":59,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":62,"sourceHtmlUrl":63},"evals\u002Fevals.json","REFERENCE","参考文档",48573,"https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fgolang-safety\u002Fevals\u002Fevals.json",{"path":65,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":66,"sourceHtmlUrl":67},"references\u002Fnil-safety.md",4810,"https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fgolang-safety\u002Freferences\u002Fnil-safety.md",{"path":69,"resourceType":60,"resourceTypeDesc":61,"sizeBytes":70,"sourceHtmlUrl":71},"references\u002Fslice-map-safety.md",5541,"https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fgolang-safety\u002Freferences\u002Fslice-map-safety.md",[73,81,88,95,102,109],{"skillNo":74,"name":75,"nameZh":6,"description":76,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":77,"licenseFileUrl":6,"sourceHtmlUrl":78,"categories":79,"keywords":80,"publishedAt":19},"01M7740FETMZY1VTYAEFY1TWY7","zustand-5","Zustand 5 state management patterns. Trigger: When managing React state with Zustand.","Apache-2.0","https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fzustand-5\u002FSKILL.md",[],[],{"skillNo":82,"name":83,"nameZh":6,"description":84,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":77,"licenseFileUrl":6,"sourceHtmlUrl":85,"categories":86,"keywords":87,"publishedAt":19},"01M773ZZM9V68SA1AKP4WF4J29","zod-4","Zod 4 schema validation patterns. Trigger: When using Zod for validation - breaking changes from v3.","https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fzod-4\u002FSKILL.md",[],[],{"skillNo":89,"name":90,"nameZh":6,"description":91,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":77,"licenseFileUrl":6,"sourceHtmlUrl":92,"categories":93,"keywords":94,"publishedAt":19},"01M773ZJFR90CQAY0N9QR40QVP","x-bookmark-quote-posts","Workflow para revisar bookmarks de X\u002FTwitter y convertirlos en drafts de quote posts. Accede a la sección de bookmarks vía browser headless, extrae posts recientes, y genera drafts con voz personal del usuario. No publica ni muta X — solo genera contenido para revisión. Trigger: X bookmarks, Twitter bookmarks, quote posts, bookmark automation, crear quote posts, revisar bookmarks, growth content X.","https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fx-bookmark-quote-posts\u002FSKILL.md",[],[],{"skillNo":96,"name":97,"nameZh":6,"description":98,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":99,"categories":100,"keywords":101,"publishedAt":19},"01M773Z2RGV3786FV310SDB0YD","writing-skills","Use when creating new skills, editing existing skills, or verifying skills work before deployment","https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fwriting-skills\u002FSKILL.md",[],[],{"skillNo":103,"name":104,"nameZh":6,"description":105,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":19},"01M773YJH3KDSW467CSS63CSRJ","writing-plans","Use when you have a spec or requirements for a multi-step task, before touching code","https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fwriting-plans\u002FSKILL.md",[],[],{"skillNo":110,"name":111,"nameZh":6,"description":112,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":77,"licenseFileUrl":6,"sourceHtmlUrl":113,"categories":114,"keywords":115,"publishedAt":19},"01M773Y3S3H2CPRK5S8YFHWB5C","work-unit-commits","Plan commits as reviewable work units. Trigger: implementation, commit splitting, chained PRs, or keeping tests and docs with code.","https:\u002F\u002Fgithub.com\u002Fdavidcoachdev\u002Fdcfiles\u002Fblob\u002Fmain\u002Fconfig\u002F.config\u002Fopencode\u002Fskills\u002Fwork-unit-commits\u002FSKILL.md",[],[]]