Skip to content
This repository was archived by the owner on Feb 21, 2022. It is now read-only.

Some minor style fixes #9

Merged
merged 1 commit into from
Nov 3, 2014
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
2 changes: 1 addition & 1 deletion .formatter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ use-sort:
sort-direction: asc

header: |
/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
8 changes: 4 additions & 4 deletions src/PHPFormatter/Command/HeaderCommand.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down Expand Up @@ -83,9 +83,9 @@ protected function execute(InputInterface $input, OutputInterface $output)
$verbose = $output->getVerbosity();
$path = $input->getArgument('path');
$dryRun = $input->getOption('dry-run');
$fileFinder = new FileFinder;
$configLoader = new ConfigLoader;
$configFinder = new ConfigFinder;
$fileFinder = new FileFinder();
$configLoader = new ConfigLoader();
$configFinder = new ConfigFinder();

/**
* This section is just for finding the right values to work with in
Expand Down
8 changes: 4 additions & 4 deletions src/PHPFormatter/Command/UseSortCommand.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down Expand Up @@ -142,7 +142,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
$options
);

$fileFinder = new FileFinder;
$fileFinder = new FileFinder();
$files = $fileFinder->findPHPFilesByPath($path);

/**
Expand All @@ -165,8 +165,8 @@ protected function execute(InputInterface $input, OutputInterface $output)
*/
private function getUsableConfig(InputInterface $input)
{
$configLoader = new ConfigLoader;
$configFinder = new ConfigFinder;
$configLoader = new ConfigLoader();
$configFinder = new ConfigFinder();

/**
* This section is just for finding the right values to work with in
Expand Down
4 changes: 2 additions & 2 deletions src/PHPFormatter/Compiler/Compiler.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down Expand Up @@ -167,7 +167,7 @@ protected function addStub(Phar $phar)
#!/usr/bin/env php
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion src/PHPFormatter/Console/Application.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
4 changes: 2 additions & 2 deletions src/PHPFormatter/Finder/ConfigFinder.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down Expand Up @@ -37,7 +37,7 @@ public function findConfigFile($path)
$config = array();
if (is_file($configFilePath)) {

$yamlParser = new YamlParser;
$yamlParser = new YamlParser();
$config = $yamlParser->parse(file_get_contents($configFilePath));
}

Expand Down
2 changes: 1 addition & 1 deletion src/PHPFormatter/Finder/FileFinder.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion src/PHPFormatter/Fixer/HeaderFixer.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion src/PHPFormatter/Fixer/Interfaces/FixerInterface.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
4 changes: 2 additions & 2 deletions src/PHPFormatter/Loader/ConfigLoader.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down Expand Up @@ -80,6 +80,6 @@ public function loadConfigValue(
return isset($configValues[$commandName])
? $configValues[$commandName]
: $commandValue
? : $defaultValue;
?: $defaultValue;
}
}
2 changes: 1 addition & 1 deletion src/PHPFormatter/PHPFormatter.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion src/PHPFormatter/Sorter/Interfaces/SorterInterface.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion src/PHPFormatter/Sorter/UseSorter.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion src/bootstrap.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion tests/PHPFormatter/Finder/ConfigFinderTest.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion tests/PHPFormatter/Finder/FileFinderTest.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
10 changes: 5 additions & 5 deletions tests/PHPFormatter/Fixer/HeaderFixerTest.php
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
<?php

/**
* This file is part of the Elcodi package.
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Elcodi.com
* Copyright (c) 2014 Marc Morera
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* Feel free to edit as you please, and have fun.
*
* @author Marc Morera <[email protected]>
* @author Aldo Chiecchia <[email protected]>
*/

namespace Mmoreram\PHPFormatter\Tests\Fixer;

use Mmoreram\PHPFormatter\Fixer\HeaderFixer;
use PHPUnit_Framework_TestCase;

use Mmoreram\PHPFormatter\Fixer\HeaderFixer;

/**
* Class HeaderFixerTest
*/
Expand Down
4 changes: 2 additions & 2 deletions tests/PHPFormatter/Loader/ConfigLoaderTest.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand All @@ -17,8 +17,8 @@

use PHPUnit_Framework_TestCase;

use Mmoreram\PHPFormatter\Loader\ConfigLoader;
use Mmoreram\PHPFormatter\Command\UseSortCommand;
use Mmoreram\PHPFormatter\Loader\ConfigLoader;

/**
* Class ConfigLoaderTest
Expand Down
2 changes: 1 addition & 1 deletion tests/PHPFormatter/Mocks/MyClass.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion tests/PHPFormatter/Mocks/MyOtherClass.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion tests/PHPFormatter/Mocks/directory/MyThirdClass.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down
2 changes: 1 addition & 1 deletion tests/PHPFormatter/Sorter/UseSorterTest.php
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php

/**
/*
* This file is part of the php-formatter package
*
* Copyright (c) 2014 Marc Morera
Expand Down