String-parsing in Nix: Difference between revisions

From NixOS Wiki
imported>Milahu
add section: Grammars
imported>Milahu
m rename section to IPv4 address
Line 31: Line 31:
https://github.com/nix-community/dream2nix/blob/main/src/subsystems/haskell/translators/cabal-freeze/parser.nix
https://github.com/nix-community/dream2nix/blob/main/src/subsystems/haskell/translators/cabal-freeze/parser.nix


=== IPv4 addresses ===
=== IPv4 address ===


https://github.com/NixOS/nix/issues/1491#issuecomment-318273971
https://github.com/NixOS/nix/issues/1491#issuecomment-318273971

Revision as of 19:33, 17 November 2022

String parsers

Some string parsers written in Nix

yaml

toml

yarn.lock

Lisp

arithmetic

https://github.com/nprindle/nix-parsec/tree/master/examples/arithmetic

cabal freeze

https://github.com/nix-community/dream2nix/blob/main/src/subsystems/haskell/translators/cabal-freeze/parser.nix

IPv4 address

https://github.com/NixOS/nix/issues/1491#issuecomment-318273971

UUID

https://github.com/nprindle/nix-parsec/tree/master/examples/uuids

Linux kernel config

https://github.com/nprindle/nix-parsec/tree/master/examples/kernel-config

Python setup.cfg

https://github.com/seppeljordan/nix-setuptools/blob/master/lib/setuptools.nix

PureScript

https://github.com/purs-nix/purs-nix/blob/master/parser.nix

Parser combinators

Build parsers from grammars

Grammars

See also