question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

File paths should be platform-independent

See original GitHub issue

Config file paths (and possibly other paths such as baseline) are stored in detekt.xml and read back as platform-dependent.

This means that if the detekt.xml is shared in VCS for the whole team to use, and not everyone is on the same OS (mix of POSIX and Windows users) the paths will not work for some folks and they’ll be bombarded by “file not found” notifications from the Detekt plugin.

The plugin should store paths in a platform-independent way and apply the correct separators at runtime.

Issue Analytics

  • State:closed
  • Created a year ago
  • Comments:6 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
rock3rcommented, Aug 7, 2022

I’m actually working on that. Hopefully will have a PR soon. Fighting a bit with IJ 😃

0reactions
rock3rcommented, Aug 7, 2022

@arturbosch I have a couple of questions for you, I pinged you on the Kotlin Slack, but I am not sure you actually use it. Let me know if you prefer other ways to get in touch.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Platform-independent file paths? - python - Stack Overflow
You can use os.path and its functions, which take care of OS-specific paths: >>> import os >>> os.path.join('app', 'subdir', 'dir', 'filename.foo') ...
Read more >
Constructing file paths that are platform independent - HUGO
Hi,. I wish to construct platform independent file paths within a template for a theme used by users across multiple operating systems. For...
Read more >
os.path – Platform-independent manipulation of file names.
When your program encounters a path name, it often needs to know whether the path refers to a file or directory. If you...
Read more >
Python 3 Quick Tip: The easy way to deal with file paths on ...
This code will work perfectly on both Windows or Mac. The problem is that it's a pain to use. Writing out os.path.join() and...
Read more >
Avoiding Platform Depedent Code
Although Java is considered platform independent (i.e. compiled Java code can ... You can use the path.separator property, or File fields when writing...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found