Skip to content

Consider dirs crate for better cross-platform support #1509

Open

Description

@maxrake

Consider better cross-platform support by creating/saving/updating the settings.yaml file in a more natural location for the OS. This can be accomplished with the dirs crate from crates.io. Currently, a local crate with the same name is used - cli/src/dirs.rs - and assumes Linux for the default location.

References:

Activity

  1. kylewillmon commented on Oct 2, 2024

    @kylewillmon
    Contributor

    The dirs crate was considered when moved files out of ~/.phylum.

    The crate uses locations that are technically correct for each OS, but that means using the very unnatural $HOME/Library/Application Support on macOS...

    Since the only concern with our current code is Windows, it probably makes more sense to update our code to use AppData on Windows rather than switching to the dirs crate for everything.

  2. maxrake commented on Oct 7, 2024

    @maxrake
    ContributorAuthor

    Reminder for possible later phylum-ci update: there is a Python package, platformdirs, that does the same thing as the dirs crate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestneeds triageNeeds to be reviewed or assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions