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

internal: support scanning path #34

Merged
merged 4 commits into from
Nov 29, 2023
Merged

internal: support scanning path #34

merged 4 commits into from
Nov 29, 2023

Conversation

jroimartin
Copy link
Contributor

This PR makes the following changes:

  • Introduce the concept of "Lava asset types". Which are asset types
    that are only valid in the context of Lava. For instance, Path.
  • Map Lava asset types to Vulcan asset types and provide tools to work
    with this mappings under a new package called assettype. For
    instance, Path maps to GitRepository.
  • Add the method gitserver.*Server.AddPath, which allows to serve
    any file path as a Git repository. This Git repository contains a
    single commit that includes all files and directories under the
    specified path.
  • Handle the Path asset type in the Lava engine.

This allows Lava users to scan any arbitrary path without the
limitations of a Git repository. For instance,

  • All ignored and non-pushed files/changes are scanned.
  • It is possible to scan a subtree within a repository.

internal/gitserver/gitserver_test.go Outdated Show resolved Hide resolved
@jroimartin jroimartin requested a review from seilagamo November 29, 2023 10:06
Copy link
Collaborator

@seilagamo seilagamo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Remember to clean the commit before merging.

@jroimartin jroimartin merged commit 3525b73 into main Nov 29, 2023
@jroimartin jroimartin deleted the target-path branch November 29, 2023 13:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants