Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge up 0.4.x into 0.5.x #151

Merged
merged 3 commits into from
May 13, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 31 additions & 1 deletion .doctrine-project.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,41 @@
"slug": "latest",
"upcoming": true
},
{
"name": "0.5",
"branchName": "0.5.x",
"slug": "0.5",
"upcoming": true
},
{
"name": "0.4",
"branchName": "0.4.x",
"slug": "0.4",
"current": true
},
{
"name": "0.3",
"branchName": "0.3.x",
"slug": "0.3",
"maintained": false
},
{
"name": "0.2",
"branchName": "0.2.x",
"slug": "0.2",
"maintained": false
},
{
"name": "0.2",
"branchName": "0.2.x",
"slug": "0.2",
"maintained": false
},
{
"name": "0.1",
"branchName": "0.1.x",
"slug": "0.1",
"current": true
"maintained": false
}
]
}
23 changes: 22 additions & 1 deletion lib/Configuration.php
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@

class Configuration
{
public const THEME_DEFAULT = 'default';
public const THEME_DEFAULT = 'default';
public const OUTPUT_FORMAT_CONSOLE = 'console';
public const OUTPUT_FORMAT_GITHUB = 'github';

/** @var string */
private $cacheDir;
Expand All @@ -53,6 +55,9 @@ class Configuration
/** @var bool */
private $warningsAsError = false;

/** @psalm-var self::OUTPUT_FORMAT_* */
private $outputFormat = self::OUTPUT_FORMAT_CONSOLE;

/** @var bool */
private $ignoreInvalidReferences = false;

Expand Down Expand Up @@ -227,6 +232,22 @@ public function isWarningsAsError(): bool
return $this->warningsAsError;
}

/**
* @psalm-return self::OUTPUT_FORMAT_*
*/
final public function getOutputFormat(): string
{
return $this->outputFormat;
}

/**
* @psalm-param self::OUTPUT_FORMAT_* $outputFormat
*/
final public function setOutputFormat(string $outputFormat): void
{
$this->outputFormat = $outputFormat;
}

public function getIgnoreInvalidReferences(): bool
{
return $this->ignoreInvalidReferences;
Expand Down