{"modulePath":"github.com/kptdev/kpt","version":"v1.0.1","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package pkgdocs\n\nCode generated by \"mdtogo\"; DO NOT EDIT.\n\n## Variables\n\n```go\nvar CatExamples = `\n  # Print all package contents from current directory.\n  $ kpt pkg cat\n\n  # Print a single resource file.\n  $ kpt pkg cat path/to/deployment.yaml\n\n  # Print a non-KRM file.\n  $ kpt pkg cat path/to/README.md\n`\n```\n\n```go\nvar CatLong = `\n  kpt pkg cat [FILE | DIR]\n\nArgs:\n\n  FILE | DIR:\n    Path to a file or a directory containing a kpt package. Displays all\n    package files: KRM resources (YAML/JSON) are formatted by default,\n    and non-KRM text files (e.g., README.md) are shown as raw content.\n    Binary files are skipped. Defaults to the current directory.\n\nFlags:\n\n  --annotate:\n    Annotate resources with their file origins. Defaults to false.\n  \n  --format:\n    Format resource config YAML before printing (reorders fields to canonical\n    order). Defaults to true.\n  \n  --recurse-subpackages, -R:\n    Print resources recursively in all the nested subpackages. Defaults to true.\n  \n  --strip-comments:\n    Remove comments from yaml. Defaults to false.\n  \n  --style:\n    yaml styles to apply. May be 'TaggedStyle', 'DoubleQuotedStyle',\n    'LiteralStyle', 'FoldedStyle', 'FlowStyle'.\n`\n```\n\n```go\nvar CatShort = `Print the contents of a package`\n```\n\n```go\nvar DiffExamples = `\n\n  # Show changes in current package relative to upstream source package.\n  kpt pkg diff\n`\n```\n\n```go\nvar DiffLong = `\n  kpt pkg diff [PKG_PATH@VERSION] [flags]\n\nArgs:\n\n  PKG_PATH:\n    Local package path to compare. diff will fail if the directory doesn't exist, or does not\n    contain a Kptfile. Defaults to the current working directory.\n  \n  VERSION:\n    A git tag, branch, or commit. Specified after the local_package with @, for\n    example my-package@master.\n    Defaults to the local package version that was last fetched.\n\nFlags:\n\n  --diff-type:\n    The type of changes to view (local by default). Following types are\n    supported:\n  \n    local: Shows changes in local package relative to upstream source package\n           at original version.\n    remote: Shows changes in upstream source package at target version\n            relative to original version.\n    combined: Shows changes in local package relative to upstream source\n              package at target version.\n    3way: Shows changes in local package and source package at target version\n          relative to original version side by side.\n  \n  --diff-tool:\n    Command line diffing tool ('diff' by default) for showing the changes.\n    Note that it overrides the KPT_EXTERNAL_DIFF environment variable.\n  \n    # Show changes using 'meld' commandline tool.\n    kpt pkg diff @master --diff-tool meld\n  \n  --diff-tool-opts:\n    Commandline options to use with the command line diffing tool.\n    Note that it overrides the KPT_EXTERNAL_DIFF_OPTS environment variable.\n  \n    # Show changes using the diff command with recursive options.\n    kpt pkg diff @master --diff-tool meld --diff-tool-opts \"-r\"\n  \n  --debug:\n    When true, prints additional debug information and does not delete the\n    staged package directories used for comparison. Defaults to false.\n\nEnvironment Variables:\n\n  KPT_EXTERNAL_DIFF:\n    Commandline diffing tool ('diff; by default) that will be used to show\n    changes.\n  \n    # Use meld to show changes\n    KPT_EXTERNAL_DIFF=meld kpt pkg diff\n  \n  KPT_EXTERNAL_DIFF_OPTS:\n    Commandline options to use for the diffing tool. For ex.\n    # Using \"-a\" diff option\n    KPT_EXTERNAL_DIFF_OPTS=\"-a\" kpt pkg diff --diff-tool meld\n  \n  KPT_CACHE_DIR:\n    Controls where to cache remote packages when fetching them.\n    Defaults to \u003cHOME\u003e/.kpt/repos/\n    On macOS and Linux \u003cHOME\u003e is determined by the $HOME env variable, while on\n    Windows it is given by the %USERPROFILE% env variable.\n`\n```\n\n```go\nvar DiffShort = `Show differences between a local package and upstream.`\n```\n\n```go\nvar GetExamples = `\n\n  # Fetch package cockroachdb from github.com/kubernetes/examples/staging/cockroachdb\n  # This creates a new subdirectory 'cockroachdb' for the downloaded package.\n  $ kpt pkg get https://github.com/kubernetes/examples.git/staging/cockroachdb@master\n\n\n  # Fetch package cockroachdb from github.com/kubernetes/examples/staging/cockroachdb\n  # This will create a new directory 'my-package' for the downloaded package if it\n  # doesn't already exist.\n  $ kpt pkg get https://github.com/kubernetes/examples.git/staging/cockroachdb@master ./my-package/\n\n\n  # Fetch package examples from github.com/kubernetes/examples at the specified\n  # git hash.\n  # This will create a new directory 'examples' for the package.\n  $ kpt pkg get https://github.com/kubernetes/examples.git/@6fe2792\n\n\n  # Create a deployable instance of examples package from github.com/kubernetes/examples\n  # This will create a new directory 'examples' for the package.\n  $ kpt pkg get https://github.com/kubernetes/examples.git/@6fe2792 --for-deployment\n`\n```\n\n```go\nvar GetLong = `\n  kpt pkg get REPO_URI[.git]/PKG_PATH[@VERSION] [LOCAL_DEST_DIRECTORY] [flags]\n\nArgs:\n\n  REPO_URI:\n    URI of a git repository containing 1 or more packages as subdirectories.\n    In most cases the .git suffix should be specified to delimit the REPO_URI\n    from the PKG_PATH, but this is not required for widely recognized repo\n    prefixes. If get cannot parse the repo for the directory and version,\n    then it will print an error asking for '.git' to be specified as part of\n    the argument.\n  \n  PKG_PATH:\n    Path to remote subdirectory containing Kubernetes resource configuration\n    files or directories. Defaults to the root directory.\n    Uses '/' as the path separator (regardless of OS).\n    e.g. staging/cockroachdb\n  \n  VERSION:\n    A git tag, branch, ref or commit for the remote version of the package\n    to fetch. Defaults to the default branch of the repository.\n  \n  LOCAL_DEST_DIRECTORY:\n    The local directory to write the package to. Defaults to a subdirectory of the\n    current working directory named after the upstream package.\n\nFlags:\n\n  --strategy:\n    Defines which strategy should be used to update the package. It defaults to\n    'resource-merge'.\n  \n      * resource-merge: Perform a structural comparison of the original /\n        updated resources, and merge the changes into the local package.\n      * fast-forward: Fail without updating if the local package was modified\n        since it was fetched.\n      * force-delete-replace: Wipe all the local changes to the package and replace\n        it with the remote version.\n  \n  --for-deployment:\n    (Experimental) indicates if the fetched package is a deployable instance that\n    will be deployed to a cluster.\n    It is ` + \"`\" + `false` + \"`\" + ` by default.\n\nEnv Vars:\n\n  KPT_CACHE_DIR:\n    Controls where to cache remote packages when fetching them.\n    Defaults to \u003cHOME\u003e/.kpt/repos/\n    On macOS and Linux \u003cHOME\u003e is determined by the $HOME env variable, while on\n    Windows it is given by the %USERPROFILE% env variable.\n`\n```\n\n```go\nvar GetShort = `Fetch a package from a git repo.`\n```\n\n```go\nvar InitExamples = `\n\n  # Creates a new Kptfile with metadata in the cockroachdb directory.\n  $ mkdir cockroachdb; kpt pkg init cockroachdb --keywords \"cockroachdb,nosql,db\"  \\\n      --description \"my cockroachdb implementation\"\n\n  # Creates a new Kptfile without metadata in the current directory.\n  $ kpt pkg init\n`\n```\n\n```go\nvar InitLong = `\n  kpt pkg init [DIR] [flags]\n\nArgs:\n\n  DIR:\n    init fails if DIR does not already exist. Defaults to the current working directory.\n\nFlags:\n\n  --description\n    Short description of the package. (default \"sample description\")\n  \n  --keywords\n    A list of keywords describing the package.\n  \n  --site\n    Link to page with information about the package.\n`\n```\n\n```go\nvar InitShort = `Initialize an empty package.`\n```\n\n```go\nvar PkgLong = `\nThe ` + \"`\" + `pkg` + \"`\" + ` command group contains subcommands for fetching, updating and describing ` + \"`\" + `kpt` + \"`\" + ` packages\nfrom git repositories.\n`\n```\n\n```go\nvar PkgShort = `Get, update, and describe packages with resources`\n```\n\n```go\nvar TreeExamples = `\n  # Show resources in the current directory.\n  $ kpt pkg tree\n\n  # Example output showing independent and dependent packages:\n  $ kpt pkg tree wordpress/\n  Package \"wordpress\" (independent)\n  ├── [Kptfile]  Kptfile wordpress\n  ├── [service.yaml]  Service wordpress\n  ├── deployment\n  │   ├── [deployment.yaml]  Deployment wordpress\n  │   └── [volume.yaml]  PersistentVolumeClaim wp-pv-claim\n  └── Package \"mysql\" (dependent)\n      ├── [Kptfile]  Kptfile mysql\n      ├── [deployment.yaml]  Deployment wordpress-mysql\n      └── [service.yaml]  Service wordpress-mysql\n`\n```\n\n```go\nvar TreeLong = `\n  kpt pkg tree [DIR]\n\nArgs:\n\n  DIR:\n    Path to a local package directory. Defaults to the current directory.\n    Displays KRM resources with their Kind and Name, and non-KRM text files\n    as plain filenames. Dotfiles and symlinks are excluded.\n`\n```\n\n```go\nvar TreeShort = `Display resources, files and packages in a tree structure.`\n```\n\n```go\nvar UpdateExamples = `\n  # Update package in the current directory.\n  # git add . \u0026\u0026 git commit -m 'some message'\n  $ kpt pkg update\n\n  # Update my-package-dir/ to match the v1.3 branch or tag.\n  # git add . \u0026\u0026 git commit -m 'some message'\n  $ kpt pkg update my-package-dir/@v1.3\n\n  # Update with the fast-forward strategy.\n  # git add . \u0026\u0026 git commit -m \"some message\"\n  $ kpt pkg update my-package-dir/@master --strategy fast-forward\n`\n```\n\n```go\nvar UpdateLong = `\n  kpt pkg update [PKG_PATH][@VERSION] [flags]\n\nArgs:\n\n  PKG_PATH:\n    Local package path to update. Directory must exist and contain a Kptfile\n    to be updated. Defaults to the current working directory.\n  \n  VERSION:\n    A git tag, branch, ref or commit. Specified after the local_package\n    with @ -- pkg@version.\n    Defaults the ref specified in the Upstream section of the package Kptfile.\n  \n    Version types:\n      * branch: update the local contents to the tip of the remote branch\n      * tag: update the local contents to the remote tag\n      * commit: update the local contents to the remote commit\n\nFlags:\n\n  --strategy:\n    Defines which strategy should be used to update the package. This will change\n    the update strategy for the current kpt package for the current and future\n    updates. If a strategy is not provided, the strategy specified in the package\n    Kptfile will be used.\n  \n      * resource-merge: Perform a structural comparison of the original /\n        updated resources, and merge the changes into the local package.\n      * fast-forward: Fail without updating if the local package was modified\n        since it was fetched.\n      * force-delete-replace: Wipe all the local changes to the package and replace\n        it with the remote version.\n\n  --preserve-explicit-null:\n    When set, fields explicitly nulled in the local package (for example\n    ` + \"`\" + `field:` + \"`\" + `, ` + \"`\" + `null` + \"`\" + `, or ` + \"`\" + `~` + \"`\" + `) are kept as null during resource-merge instead of\n    being deleted. This changes the default for the current and future updates\n    and is persisted as ` + \"`\" + `upstream.preserveExplicitNull` + \"`\" + ` in the Kptfile.\n    Only applies to the resource-merge strategy. Defaults to false.\n\nEnv Vars:\n\n  KPT_CACHE_DIR:\n    Controls where to cache remote packages when fetching them.\n    Defaults to \u003cHOME\u003e/.kpt/repos/\n    On macOS and Linux \u003cHOME\u003e is determined by the $HOME env variable, while on\n    Windows it is given by the %USERPROFILE% env variable.\n`\n```\n\n```go\nvar UpdateShort = `Apply upstream package updates.`\n```\n\n","path":"github.com/kptdev/kpt/internal/docs/generated/pkgdocs","name":"pkgdocs","synopsis":"Code generated by \"mdtogo\"; DO NOT EDIT.","isRedistributable":true}
