Skip to content

Improve user home detection #36

@jordeu

Description

@jordeu

Description

On some environments the user home it is not correctly discovered and it returns a ? instead of the real path. We can use the same approach already implemented to detect the user, first check if HOME environment variable exists, otherwise fallback to System.getProperty("user.home").

Example

$ ./tw-agent 8e2e618d-2bc2-4d82-8e20-407ce0db6c08
11:16:46.738 INFO - Established active environments: [cli]
11:16:46.753 ERROR- The work directory '?/work' do not exists. Create it or provide a different one using '--work-dir'.

NOTE: A non-static linked version of tw-agent do not have this problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions