Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pkg/cdi: add functions for generating Spec names and removing Spec files. #77

Merged
merged 6 commits into from
Oct 31, 2022

Commits on Sep 27, 2022

  1. pkg/cdi: fix incorrect WriteSpec docstring.

    Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
    klihub committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    c6bf82c View commit details
    Browse the repository at this point in the history
  2. pkg/cdi: add RemoveSpec() for removing Spec files.

    RemoveSpec() can be used to remove a Spec file written
    by WriteSpec(). It takes the same name that was passed
    to WriteSpec() to create the file.
    
    Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
    klihub committed Sep 27, 2022
    Configuration menu
    Copy the full SHA
    c5a7189 View commit details
    Browse the repository at this point in the history

Commits on Oct 27, 2022

  1. pkg/cdi: add Spec name generation functions.

    Add functions for generating ordinary or transient
    Spec file names. The generated names can be passed
    to WriteSpec() to create the actual Spec files and
    to RemoveSpec() to remove them.
    
    Also update the package introduction in the golang
    docs describing how dynamic Spec files should be
    generated using the API.
    
    Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
    klihub committed Oct 27, 2022
    Configuration menu
    Copy the full SHA
    2fde79d View commit details
    Browse the repository at this point in the history
  2. pkg/cdi: default to YAML spec encoding.

    Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
    klihub committed Oct 27, 2022
    Configuration menu
    Copy the full SHA
    7c8505c View commit details
    Browse the repository at this point in the history
  3. pkg/cdi: unexport spec.Write(), NewSpec().

    This should reduce confusion about how generates Specs
    should be written (cache.WriteSpec() vs. spec.Write())
    and also reduce the possibility/temptation for users to
    bypass the registry/cache when interacting with Specs.
    
    Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
    klihub committed Oct 27, 2022
    Configuration menu
    Copy the full SHA
    98524c3 View commit details
    Browse the repository at this point in the history
  4. pkg/cdi: expose [specs.]CurrentVersion.

    Alias specs.CurrentVersion as pkg/cdi.CurrentVersion.
    
    Signed-off-by: Krisztian Litkey <krisztian.litkey@intel.com>
    klihub committed Oct 27, 2022
    Configuration menu
    Copy the full SHA
    a5fbc2f View commit details
    Browse the repository at this point in the history