`init`
Initialize an empty package.
init
initializes an existing empty directory as a kpt package by adding a
Kptfile and a placeholder README.md
file.
Synopsis #
$$kpt pkg init [DIR] [flags]$$
Args #
$$DIR:
init fails if DIR does not already exist. Defaults to the current working directory.$$
Flags #
$$--description
Short description of the package. (default "sample description")
--keywords
A list of keywords describing the package.
--site
Link to page with information about the package.$$
Examples #
{{ /* % hide % */ }}
$$# Set up workspace for the test.
TEST_HOME=$(mktemp -d)
cd $TEST_HOME$$
{{ /* % /hide % */ }}
# Creates a new Kptfile with metadata in the cockroachdb directory.
$ mkdir cockroachdb; kpt pkg init cockroachdb --keywords "cockroachdb,nosql,db" \
--description "my cockroachdb implementation"
# Creates a new Kptfile without metadata in the current directory.
$ kpt pkg init
Last modified June 16, 2025: Move docs to hugo (#4215) (2f0d4026)