Repository navigation
Pack localized assemblies. - #1816
Conversation
| paket ("pack -v output \"" + outPath) scenario |> ignore | ||
| ZipFile.ExtractToDirectory(package, outPath) | ||
|
|
||
| Path.Combine(outPath, "lib", "net45", "LocalizedLib.dll") |> checkFileExists |
There was a problem hiding this comment.
Could you use </> operator defined in Paket.IO (it is AutoOpen so you don't even have to open the namespace):
outPath </> "lib" </> "net45" </> "LocalizedLib.dll" |> checkFileExists
There was a problem hiding this comment.
While it looks sweet I have not seen it in the rest of the code so not sure. Trying to stay consistent with the codebase. Also as a noob Path.Combine(...) is nice as I know what it does.
As always, thanks for taking the time to read!
There was a problem hiding this comment.
Yes, it's minor thing.
That same operator is defined in FAKE and pretty much any codebase dealing with paths so I thin it is not too far from reach for average F# developer.
You can use go to definition on operators also 😄
f45ed83 to
2c47583
Compare
|
Why do we show warnings and when? I mean having no satellite assemblies is the 95% case |
|
The warning is shown here, it happens when:
No localization should not give a warning. |
Fixes since previous attempt: - fsprojects#1810 should be ok now. - Outputting warning instead of throwing if satellite dll is not found. - Better pattern for finding languages. - Checking that matches for the regex is a culture name.
2c47583 to
f9508c6
Compare
| open System.Collections.Generic | ||
| open System.Globalization | ||
|
|
||
| [<CompilationRepresentation (CompilationRepresentationFlags.ModuleSuffix)>] |
There was a problem hiding this comment.
Unless you have a type Cultures under Paket namespace, I don't think we need those attributes (which is used to disambiguate between module and type bearing same name).
There was a problem hiding this comment.
I copy pasted them from the Cache module, no idea what they mean.
There was a problem hiding this comment.
This is needed for Cache module because there is also a Cache type under same namespace.
F# will coallesce both to expose them as Cache but the module need to be given that attribute which under the hood suffixes the static class with Module.
We don't need it for this Cultures since there is no Cultures type that would conflict.
There was a problem hiding this comment.
Thanks for the explanation, removing it.
Oh, too late.
There was a problem hiding this comment.
there is always room for new PR ;-)
There was a problem hiding this comment.
I was gonna try to fix the uri issue but was too slow :D
There was a problem hiding this comment.
That one is a bit tricky. not sure if my fix was good. have to think about it a bit more.
|
there is still one related test failing on mono: https://travis-ci.org/fsprojects/Paket/builds/145555619 |
|
Checking it out, didn't see that one before, strange. |
|
I assume there is something not commited |
|
|
|
Looks like the templates are missing, must have dumbed it during some rebase. Opening a new WIP PR for fixing it. |
Second attempt at #1806.
Thank you for all the help @smoothdeveloper!