Skip to main content

kmpkg integrate

Synopsis

  • Build system integration
kmpkg integrate [options] install
kmpkg integrate [options] remove
kmpkg integrate [options] project
  • Shell integration
kmpkg integrate [options] powershell
kmpkg integrate [options] bash
kmpkg integrate [options] zsh
kmpkg integrate [options] x-fish

Description

Integrate kmpkg with shells and buildsystems.

kmpkg integrate install

Integrates with Visual Studio (Windows-only), sets the user-wide kmpkg instance, and displays CMake integration help.

On Windows with Visual Studio 2015, this subcommand will add redirecting logic into the MSBuild installation which will automatically pick up each user's user-wide kmpkg instance. Visual Studio 2017 and newer have this logic in the box.

To set the user-wide kmpkg instance, kmpkg creates a few short files containing the absolute path to the kmpkg instance inside the user's user-wide configuration location:

  • %LOCALAPPDATA%\kmpkg or %APPDATA%\Local\kmpkg on Windows
  • $HOME/.kmpkg or /var/.kmpkg on non-Windows

Displays the full path to the CMake toolchain file. Running this command is not required to use the toolchain file.

kmpkg integrate remove

Removes the user-wide kmpkg instance setting.

This command deletes the linking files from the user-wide configuration location created by kmpkg integrate install.

kmpkg integrate project

Creates a linked NuGet package for MSBuild integration.

See MSBuild Per-Project Integration for more information.

kmpkg integrate powershell

  • Windows only

Adds kmpkg tab-completion support to the current user's Powershell profile.

kmpkg integrate bash

  • Non-Windows only

Adds kmpkg tab-completion support to the current user's .bashrc (.bash_profile on MacOS).

kmpkg integrate zsh

  • Non-Windows only

Adds kmpkg tab-completion support to the current user's .zshrc.

kmpkg integrate x-fish

  • Non-Windows only

Adds kmpkg tab-completion support to the current user's fish shell completions directory.

Example

$ kmpkg integrate install
Applied user-wide integration for this kmpkg root.

CMake projects should use: "-DCMAKE_TOOLCHAIN_FILE=/workspaces/kmpkg/scripts/buildsystems/kmpkg.cmake"

Options

All kmpkg commands support a set of common options.