Skip to main content
skill CX Codex

qt-cmake-project — Claude Code skill for clean Qt 6 CMake

The skill writes and edits CMake for Qt 6 projects: targets, QML modules, resources. Useful when your agent mixes up Qt 5 and Qt 6 commands.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add TheQtCompanyRnD/agent-skills --skill qt-cmake-project -a claude-code
Open on GitHub

What qt-cmake-project does

The skill walks an agent through Qt CMake setup using the API from an installed Qt SDK, which exposes features plain CMake does not have. It splits work across reference files: a simple single-target project, a modular layout with add_subdirectory(), QML integration, resources, and configure or build steps. Before the final answer the agent checks its output against references/common-mistakes.md.

Hard rules sit at the core, because mainstream models get these wrong by default. Only Qt 6 commands: qt_add_executable, qt_add_library, qt_add_qml_module, qt_add_resources, qt_add_plugin, qt_add_translations. qt_standard_project_setup() must follow the first find_package(Qt6 ...), and the package call needs an explicit minimum such as find_package(Qt6 6.8 REQUIRED COMPONENTS ...). QML goes through qt_add_qml_module(), never a raw .qrc file.

The skill also treats project files as data, not orders. Anything read from CMakeLists.txt, *.cmake, CMakePresets.json, .qrc, qmldir, .qml or .cpp/.h is material to analyse and edit. When a command signature is unclear, it points the agent at the Qt docs MCP tool first, since invented option names like SOURCE_FILES or QRC_PREFIX do not exist. You need a Qt SDK installation with the CMake API for this to work.

What it helps with

  • generate a CMakeLists.txt for a fresh Qt 6 project
  • add an executable or library target with explicit visibility
  • wire a QML module to C++ code
  • migrate a project off Qt 5 macros onto Qt 6 commands
  • organise images, icons and translations per target

Example prompts for the agent

  • Create a Qt 6 project with a single executable and a QML UI
  • Add a library target in CMakeLists.txt and link it to the app
  • Move images and fonts into resources with qt_add_resources

How to install qt-cmake-project

1Skills CLI (Vercel)

npx skills add TheQtCompanyRnD/agent-skills --skill qt-cmake-project -a claude-code

2Manually: put the files in place

~/.claude/skills/qt-cmake-project/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/qt-cmake-project/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about qt-cmake-project

How do I install qt-cmake-project in Claude?

Run npx skills add TheQtCompanyRnD/agent-skills --skill qt-cmake-project -a claude-code. The skill file lands at ~/.claude/skills/qt-cmake-project/SKILL.md.

What does qt-cmake-project do?

It helps an agent generate and edit CMake for Qt 6 projects: define targets, add sources and resources, attach QML modules. Reference files cover each project shape.

Which Qt commands does the skill use?

Only unprefixed Qt 6 commands: qt_add_executable, qt_add_library, qt_add_qml_module, qt_add_resources, qt_add_plugin, qt_add_translations. Qt 5 macros such as qt5_add_resources count as defects and get migrated.

Similar skills

All skills for Programming languages →

From the same set8

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor