casey / casey/intermodal

Check for non-portable file names

Open
#41 0 comments 0 reactions 0 assignees View on GitHub
enhancement
Dominant language
Rust
Stars
659
Forks
36
Avg merge
18m
Merged PRs (30d)
2

Description

Check for filenames that might cause problems on different systems and throw an error, unless a flag is passed. I'm not sure how strict to be. Some ideas for checks, some which are clearly too strict:

- Only allow ascii: Since non-ascii encoding may be buggy
- Don't allow spaces: For shell-safe paths
- Don't allow siblings whose names differ only by case: For case sensitive file systems)
- Only allow `/a-zA-Z0-9_.-/`: maximum crazy
- Don't allow leading `-`: conflicts with options and flags
- Dont' allow `\/:*?"<>|`: I think for windows

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.