ForNeVeR / ForNeVeR/TruePath

Platform-specific methods (quoting etc.) for local paths

Ouverte
#3 0 commentaires 0 réactions 0 personnes assignées Voir sur GitHub
enhancement help wanted
Langage dominant
C#
Étoiles
104
Forks
18
Merge moyen
9 min
PR mergées (30 j)
2

Description

First of all, there are some specific APIs for paths (say, `GetCompressedFileSize` on Windows, also Unix rights and Windows ACLs) which we may seek to implement.

Second: there are several absolutely different ways to convert paths to strings. For certain Windows APIs, it's important to handle these properly (i.e. quote paths, or append a UNC prefix where appropriate, see [Vacuum's `AbsolutePath`](https://github.com/ForNeVeR/Vacuum/blob/c16aab2b8b9e164d4889a17494160dbe315df2f0/Vacuum/AbsolutePath.fs#L49-L57) as inspiration).

Obviously, not all users want the platform-specific parts of the file path API, so we may include some separate platform-specific packages for all of this.

I imagine our users calling something like
```csharp
LocalPath fsp = …;
MyNativeFuncs.DoWinApiOperation(fsp.QuoteWinApi()); // QuoteWinApi is an extension
```

Or, say
```csharp
LocalPath fsp = …;
WindowsACL acl = fsp.GetAcl(); // an extension from Win package
UnixRights rights = fsp.GetUnixPermissions(); // an extension from Unix package
```

Guide de contribution

Ouvrir le guide de contribution

Piste de recherche

Commencez par examiner l’abstraction LocalPath existante et l’implémentation Vacuum AbsolutePath liée, pour le quoting des chemins et la gestion de UNC. L’issue ne nomme aucun fichier ni test du dépôt ; sa finalisation nécessiterait de définir précisément le périmètre des API et des packages de chemins spécifiques aux plateformes, notamment le quoting Windows, les ACLs et les permissions Unix.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
csharp
Domaine
operating-systems
Type d'issue
Fonctionnalité
Difficulté
5/5
Temps estimé
Plus d'une semaine
Activité
À l'abandon
Clarté
À clarifier
Accessibilité débutants
20/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.