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

Fix ability to import the CLI repository as module #1671

Merged
merged 5 commits into from
Aug 12, 2024
Merged

Commits on Aug 12, 2024

  1. Fix importing the CLI repository as library

    While investigating #1629, I found that Go doesn't allow characters outside the
    set documented at https://pkg.go.dev/golang.org/x/mod/module#CheckFilePath.
    
    To fix this, I changed the relevant test case to create the fixtures it needs
    instead of loading it from the testdata directory (in `renderer_test.go`).
    
    Some test cases in `config_test.go` depended on templated paths without needing
    to do so. In the process of fixing this, I refactored these tests slightly to
    reduce dependencies between them.
    
    This change also adds a test case to ensure that all files in the repository
    are allowed to be part of a module (per the earlier `CheckFilePath` function).
    
    Fixes #1629.
    pietern committed Aug 12, 2024
    Configuration menu
    Copy the full SHA
    e5bcedf View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    912a48e View commit details
    Browse the repository at this point in the history
  3. Comment

    pietern committed Aug 12, 2024
    Configuration menu
    Copy the full SHA
    126309f View commit details
    Browse the repository at this point in the history
  4. Run ToSlash

    pietern committed Aug 12, 2024
    Configuration menu
    Copy the full SHA
    9e4e243 View commit details
    Browse the repository at this point in the history
  5. Use backticks for path

    pietern committed Aug 12, 2024
    Configuration menu
    Copy the full SHA
    2dbe4f7 View commit details
    Browse the repository at this point in the history