<commit_before>
                          
   ROADMAP-PORTABLE-FILES  
                          



Logo: /portable/files with programming font, different colors for slashes, and maybe dark terminal-like background

Link portable-node-guide to this, and vice-versa

Language-agnostic (advertise it)

Call it portable-lint

Make lint rules configurable
  - i.e. must be a conf file

Allow toggling rules on|ogg

Allow autofix
  - including dryrun

See other platforms eslint runs on: VS code extension, etc.

Ignoring files: see what eslint is doing???

Output:
  - abstract reporters
  - see what eslint is doing???

Supports:
  - Windows: NTFS, ReFS
  - Linux: ext3, ext4, XFS, ZFS, BTRFS
  - Mac: APFS, HFS+
  - use lowest common denominator. No OPTS.filesystem|os

On directory:
  - recursive
  - return array of errors
     - option to stop at first
  - try to find package root up
     - npx example???

On file:
  - validate not symlink

On path:
  - see my notes
     - tilde should be allowed if not whole filename
  - Return path after path.normalize() applied

test on my root directory to see what is not portable

By default throws, but there is an option to remove that

PORTABLE-PATH('PATH')[->ERROR]
  - is string
  - is not empty (after trimming)
  - strip root on Windows (backslashes can be slashes):
     - LETTER:\
     - \\HOST\
     - \\?[\UNC]\ (can be combined with one of two above)
     - \\.\
  - then path.normalize()
  - try to fix below issues (e.g. path starting with ~ -> process.homedir())
  - allow both / and \ on Windows, but no \ on Unix
  - does not start with `-` -> creates confusion with CLI flags
  - does not end with space or dot -> Windows
  - no tilde on Windows
  - no whitespaces -> uses on CLI to separate arguments
  - no non-ASCII -> it does not work well with cmd.exe (which does not have Unicode support by default)
  - no [ ] # % & { } $ ! ' ` | " < > * ? ; -> special Bash meaning
  - no starting with ~[/...] or ~user[/...] -> $HOME with Bash but not on Windows CLI
  - no ^ + @ -> special Windows CLI meaning
  - no `:` -> invalid on Windows|Mac
  - no control chars -> invalid on Windows
  - no * " | < > ? -> invalid on Windows
  - max filename length 255 -> for most filesystems
  - max path 260 -> Windows
  - invalid filenames: com1, com2, com3, com4, com5, com6, com7, com8, com9, lpt1, lpt2, lpt3, lpt4, lpt5, lpt6, lpt7, lpt8,
    lpt9, con, nul, prn, aux -> Windows
  - is lowercase -> NTFS/APFS/HFS+ are case insensitive

Change descriptions (including in Gitter, in package.json and on GitHub)


README INTRO ==>

Operating systems and file systems have different constraints for file paths and filenames: maximum length, allowed characters, etc.

`portable-path` ensures file paths are valid on any OS (Windows/Mac/Linux/BSD). Files are usually copied to different OS due to:
  - library used by users
  - different environments (development vs production)
  - colleagues/contributors with different machines
  - continuous integration run on multiple OS
  - SaaS/PaaS provider

For both source files and dynamic files<commit_msg>no commit message<commit_after>
                          
   ROADMAP-PORTABLE-FILES  
                          



Logo: /portable/files with programming font, different colors for slashes, and maybe dark terminal-like background

Link portable-node-guide to this, and vice-versa

Language-agnostic (advertise it)

Call it portable-lint

Make lint rules configurable
  - i.e. must be a conf file

Allow toggling rules on|ogg

Allow autofix
  - including dryrun

See other platforms eslint runs on: VS code extension, etc.

Ignoring files: see what eslint is doing???

Output:
  - abstract reporters
  - see what eslint is doing???

Supports:
  - Windows: NTFS, ReFS
  - Linux: ext3, ext4, XFS, ZFS, BTRFS
  - Mac: APFS, HFS+
  - use lowest common denominator. No OPTS.filesystem|os

On directory (recursive):
  - def: try to find package root up
  - return array of errors
     - option to stop at first

On file|directory (non-recursive):
  - validate not symlink

On path:
  - see my notes
     - tilde should be allowed if not whole filename
  - Return path after path.normalize() applied

By default throws, but there is an option to remove that

PORTABLE-PATH('PATH')[->ERROR]
  - is string
  - is not empty (after trimming)
  - strip root on Windows (backslashes can be slashes):
     - LETTER:\
     - \\HOST\
     - \\?[\UNC]\ (can be combined with one of two above)
     - \\.\
  - then path.normalize()
  - try to fix below issues (e.g. path starting with ~ -> process.homedir())
  - allow both / and \ on Windows, but no \ on Unix
  - does not start with `-` -> creates confusion with CLI flags
  - does not end with space or dot -> Windows
  - no tilde on Windows
  - no whitespaces -> uses on CLI to separate arguments
  - no non-ASCII -> it does not work well with cmd.exe (which does not have Unicode support by default)
  - no [ ] # % & { } $ ! ' ` | " < > * ? ; -> special Bash meaning
  - no starting with ~[/...] or ~user[/...] -> $HOME with Bash but not on Windows CLI
  - no ^ + @ -> special Windows CLI meaning
  - no `:` -> invalid on Windows|Mac
  - no control chars -> invalid on Windows
  - no * " | < > ? -> invalid on Windows
  - max filename length 255 -> for most filesystems
  - max path 260 -> Windows
  - invalid filenames: com1, com2, com3, com4, com5, com6, com7, com8, com9, lpt1, lpt2, lpt3, lpt4, lpt5, lpt6, lpt7, lpt8,
    lpt9, con, nul, prn, aux -> Windows
  - is lowercase -> NTFS/APFS/HFS+ are case insensitive

Change descriptions (including in Gitter, in package.json and on GitHub)

test on my root directory to see what is not portable


README INTRO ==>

Operating systems and file systems have different constraints for file paths and filenames: maximum length, allowed characters, etc.

`portable-path` ensures file paths are valid on any OS (Windows/Mac/Linux/BSD). Files are usually copied to different OS due to:
  - library used by users
  - different environments (development vs production)
  - colleagues/contributors with different machines
  - continuous integration run on multiple OS
  - SaaS/PaaS provider

For both source files and dynamic files
{'fraction_non_alphanumeric': 0.17031916458302693, 'fraction_numerical': 0.0076481835564053535, 'mean_word_length': 3.138770541692027, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 41, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5306091', 'n_tokens_mistral': 3696, 'n_tokens_neox': 3617, 'n_words': 821}