跳到正文
TakoAPI
返回技能列表

makefile-build

由 gitgoodordietrying 提供

DevOps & Cloud
1.4k下载量由 clawskills.sh 提供
3星标
0浏览量
0 个赞登录后即可为这个技能点赞
—暂无评分
你的评分

简介

Write Makefiles for any project type.

描述

该技能的功能

Helps write Makefiles for build automation across any language or project type. Covers targets, variables, dependencies, phony targets, and pattern rules. Also covers Just and Task as simpler alternatives to Make.

Covers Make's notoriously confusing TAB requirement and phony target pitfalls alongside practical patterns for Go, Python, Node.js, and Docker, saving time spent reading man pages.

何时使用

  • Setting up a shared build workflow for a Go or Python repo
  • Replacing long Docker CLI commands with short make targets
  • Running lint, test, and build in the right order with one command
  • Adding a self-documenting help target to an existing project
  • Migrating from a Makefile to a Justfile or Taskfile

示例工作流

输入

User asks: Create a Makefile for a Go project with build, test, lint, and clean targets

智能体
  1. 1

    Identifies the project language as Go and the required targets

  2. 2

    Generates a Makefile with .PHONY declaration for all non-file targets

  3. 3

    Adds automatic variables like $@ and $^ to build and compile rules

  4. 4

    Includes a self-documenting help target using grep and awk on ## comments

  5. 5

    Sets VERSION using git describe --tags --always via shell assignment

输出

A complete Makefile with build, test, lint, clean, and help targets, correct TAB indentation, and a VERSION variable derived from git tags

安装

clawhub install gitgoodordietrying/makefile-build

运行 CLI 命令,或把这段提示词粘贴到 Claude Code、Cursor、Codex 或你在用的任意编程智能体里。

链接