filepath icon indicating copy to clipboard operation
filepath copied to clipboard

Haskell FilePath core library

Results 41 filepath issues
Sort by recently updated
recently updated
newest added

Windows seems to interpret paths differently than on POSIX systems. - On POSIX, `/sym/link/../foo` refers to `/target/dir/../foo ≡ /target/foo` (`..` expands after dereferencing). - On Windows, `C:\sym\link\..\foo` always refers to...

enhancement

Is there really no function to get the root directory? 😳 ```hs rootDirectory :: FilePath -> FilePat rootDirectory "/directory/other.ext" == "/" rootDirectory "directory/other.ext" == "directory" rootDirectory "/foo/bar/baz" == "/" rootDirectory...

discussion

The intention is to strip away a common prefix and return the relative FilePath, if and only if there is a common prefix. Possible function signature: ```haskell stripPrefix :: --...

enhancement

It may be interesting to have benchmarks, in case the internal filepath representation changes and we want to understand both time and space.

enhancement

In the Windows version of the API, `"//foo" "txt" == "//foo\\.txt"`. That's not what anyone expects, and doesn't match the .NET conventions for filepaths. It also means Shake can't use...

ghc-8.2
enhancement

Two useful properties of filepath operators are being idempotent (as you might hope `normalise` was) and being valid lenses, specifically obeying: ``` view l (set l b a) = b...

ghc-8.2
enhancement

Migrated from https://ghc.haskell.org/trac/ghc/ticket/8752: ## @joeyh said: "Combine two paths, if the second path isAbsolute, then it returns the second." But, the implementation of combine checks if the first character of...

ghc-8.2
discussion

``` writeFile "foo " "" writeFile "bar" "" doesFileExist "foo" -- True doesFileExist "foo " -- True doesFileExist "bar " -- True ``` Seemingly any trailing spaces in a path...

discussion

While working on https://github.com/commercialhaskell/path/pull/192 I noted that it might be helpful to have a separate type for a path component for some use cases. Since we have the nice AFPP-style...

I'm trying to read and write lists of OsPaths (actually just PosixPaths in case that matters) to files. I want to avoid doing any conversion or interpretation if possible---just treat...

discussion