-
-
Notifications
You must be signed in to change notification settings - Fork 15.3k
Permalink
Choose a base ref
{{ refName }}
default
Choose a head ref
{{ refName }}
default
Comparing changes
Choose two branches to see what’s changed or to start a new pull request.
If you need to, you can also or
learn more about diff comparisons.
Open a pull request
Create a new pull request by comparing changes across two branches. If you need to, you can also .
Learn more about diff comparisons here.
base repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: 5e4c49463607
Could not load branches
Nothing to show
Loading
Could not load tags
Nothing to show
{{ refName }}
default
Loading
...
head repository: NixOS/nixpkgs
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: 07eb21ceaf7a
Could not load branches
Nothing to show
Loading
Could not load tags
Nothing to show
{{ refName }}
default
Loading
- 8 commits
- 5 files changed
- 1 contributor
Commits on Jan 23, 2020
-
lib/cli: unexport symbols & sort with generators
lib/cli is very similar to generators, so it should follow largely the same interface. Similar to how generators isn’t exported, we should also namespace cli by default (plus “cli” is only three characters to type).
Configuration menu - View commit details
-
Copy full SHA for 88a7f65 - Browse repository at this point
Copy the full SHA 88a7f65View commit details -
lib/cli: encodeGNUCommandLine -> toGNUCommandLineShell
The semantic difference between `encode` and `to` is not apparent. Users are likely to confuse both functions (which leads to unexpected error messages about the wrong types). Like in `generators.nix`, all functions should be prefixed by `to`. Furthermore, converting to a string depends on the target context. In this case, it’s a POSIX shell, so we should name it that (compare `escapeShellArg` in `strings.nix`). We can later add versions that escape for embedding in e.g. python scripts or similar.
Configuration menu - View commit details
-
Copy full SHA for 582354d - Browse repository at this point
Copy the full SHA 582354dView commit details -
Configuration menu - View commit details
-
Copy full SHA for 6841f40 - Browse repository at this point
Copy the full SHA 6841f40View commit details -
Configuration menu - View commit details
-
Copy full SHA for b2654c2 - Browse repository at this point
Copy the full SHA b2654c2View commit details -
lib/cli: rename
renderX
options tomkX
Mirrors the naming scheme in `generators.nix`, for consistency. Also rename `key` to `k` and value to `v` to aid readability to the code structure.
Configuration menu - View commit details
-
Copy full SHA for e71e1be - Browse repository at this point
Copy the full SHA e71e1beView commit details -
lib/generators: floats are not supported in mkValueStringDefault
They are cut off after a few decimal places; we cannot in good faith define a default string representation with that.
Configuration menu - View commit details
-
Copy full SHA for 18520b7 - Browse repository at this point
Copy the full SHA 18520b7View commit details -
lib/cli: mkKey -> mkOptionName, use generators.mkValueStringDefault
Let’s call them by what they are, option names. `generators.mkValueStringDefault` is a better value string renderer than plain `toString`. Also add docs to all options.
Configuration menu - View commit details
-
Copy full SHA for 7228a3c - Browse repository at this point
Copy the full SHA 7228a3cView commit details
Commits on Jan 24, 2020
-
Merge pull request #78337 from Profpatsch/lib-improve-cli-module
lib: improve cli module
Configuration menu - View commit details
-
Copy full SHA for 07eb21c - Browse repository at this point
Copy the full SHA 07eb21cView commit details
There are no files selected for viewing