Merge branch 'master' of github.com:potassco/plasp

This commit is contained in:
Patrick Lühne 2016-05-25 23:02:17 +02:00
commit dda81e9011
4 changed files with 22 additions and 11 deletions

14
CHANGELOG.md Normal file
View File

@ -0,0 +1,14 @@
# Change Log
## (unreleased)
Features:
* supports input from std::cin
## 3.0.0 (2016-05-24)
Features:
* parses [SAS](http://www.fast-downward.org/TranslatorOutputFormat) files created with [Fast Downward](http://www.fast-downward.org/)
* experimental translation from SAS to ASP facts

View File

@ -1,6 +1,6 @@
The MIT License (MIT)
# The MIT License (MIT)
Copyright (c) 2016 Patrick Lühne
Copyright © 2016 Patrick Lühne
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal

View File

@ -1,6 +1,7 @@
# plasp—Translate PDDL to ASP
[![Build Status](https://travis-ci.org/potassco/plasp.svg?branch=master)](https://travis-ci.org/potassco/plasp)
[![GitHub Release](https://img.shields.io/github/release/potassco/plasp.svg?maxAge=2592000)](https://github.com/potassco/plasp/releases)
[![Build Status](https://img.shields.io/travis/potassco/plasp/master.svg?maxAge=2592000)](https://travis-ci.org/potassco/plasp?branch=master)
`plasp` 3 is in early development and not intended for productive use yet.

View File

@ -57,16 +57,12 @@ int main(int argc, char **argv)
return EXIT_SUCCESS;
}
if (!variablesMap.count("input"))
{
std::cerr << "Error: No input file specified" << std::endl << std::endl;
printHelp();
return EXIT_FAILURE;
}
try
{
const auto sasDescription = plasp::sas::Description::fromFile(variablesMap["input"].as<std::string>());
const auto sasDescription = variablesMap.count("input")
? plasp::sas::Description::fromFile(variablesMap["input"].as<std::string>())
: plasp::sas::Description::fromStream(std::cin);
const auto sasTranslator = plasp::sas::TranslatorASP(sasDescription);
sasTranslator.translate(std::cout);
}