isStorePath
lib.strings.isStorePath
Docs pulled from | This Revision | 17 minutes ago
Check whether a value x
is a store path.
Inputs
x
- 1. Function argument
Type
isStorePath :: a -> bool
Examples
lib.strings.isStorePath
usage example
isStorePath "/nix/store/d945ibfx9x185xf04b890y4f9g3cbb63-python-2.7.11/bin/python"
=> false
isStorePath "/nix/store/d945ibfx9x185xf04b890y4f9g3cbb63-python-2.7.11"
=> true
isStorePath pkgs.python
=> true
isStorePath [] || isStorePath 42 || isStorePath {} || …
=> false