2017 © Pedro Peláez
 

library vdf-parser

An open-source VDF parser for Valve's proprietary format used in Source games.

image

lukezbihlyj/vdf-parser

An open-source VDF parser for Valve's proprietary format used in Source games.

  • Friday, February 13, 2015
  • by lukezbihlyj
  • Repository
  • 0 Watchers
  • 6 Stars
  • 872 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 3 Forks
  • 4 Open issues
  • 2 Versions
  • 14 % Grown

The README.md

VDF Parser

An open-source VDF parser for Valve's proprietary format used in Source games. This package is 100% tested and available for use in any project under the MIT license. The parser currently supports all features of VDF, including:, (*1)

  • Arbitrary whitespace, including tab characters and spaces.
  • Comments, which will be ignored during parsing.
  • Escaped strings, allowing backslash escaping inside strings for both keys and values.
  • Nested arrays, using recursion.

Installation

Via Composer

Add the following to your composer.json file and run composer update to update the dependencies and pull in the new package., (*2)

"require": {
    "lukezbihlyj/vdf-parser": "~1.0"
}

Usage

Parsing

$string = <<<VDF
{
    "key" "value"
}
VDF;

$parser = new VdfParser\Parser;
$result = $parser->parse($string);

//
// $result = [
//     'key' => 'value'
// ]
//

Testing

Unit tests are available and we strive to achieve 100% code coverage. Running the test suite is incredibly simple., (*3)

$ composer install
$ php vendor/bin/phpunit -c test/phpunit.xml

In addition to the phpunit results being output to the terminal, code coverage documentation will also be generated under the build/ directory., (*4)

The Versions

13/02 2015

dev-master

9999999-dev https://github.com/lukezbihlyj/vdf-parser

An open-source VDF parser for Valve's proprietary format used in Source games.

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

The Development Requires

parser valve vdf

13/02 2015

1.0

1.0.0.0 https://github.com/lukezbihlyj/vdf-parser

An open-source VDF parser for Valve's proprietary format used in Source games.

  Sources   Download

MIT

The Requires

  • php >=5.4.0

 

The Development Requires

parser valve vdf