Skip to content

Composer integration, PSR coding standards#6

Open
a-vasyliev wants to merge 8 commits intothomasbachem:masterfrom
a-vasyliev:master
Open

Composer integration, PSR coding standards#6
a-vasyliev wants to merge 8 commits intothomasbachem:masterfrom
a-vasyliev:master

Conversation

@a-vasyliev
Copy link
Copy Markdown

Hi, here is my proposal of improvement of your great work. Thank you for nice script. I've only added possibility to integrate your work into Composer to be able easily use it inside Composer-based projects. Also, I've found useful to migrate to PSR coding standards (it is used by most modern big PHP projects)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use git mv to move this file.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

git mv might not do what you think it does. He likely made enough changes to the file that it's no longer recognized as a rename.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@evanpurkhiser Thank you)

@malukenho
Copy link
Copy Markdown

👍

@ream88
Copy link
Copy Markdown

ream88 commented Nov 24, 2015

Please merge this!

#!/usr/bin/env php
<?php

include(__DIR__ . '/../array-converter.php');
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

include is a special language construct

include __DIR__ . DIRECTORY_SEPARATOR . '..' . DIRECTORY_SEPARATOR  . 'array-converter.php';

@angelxmoreno
Copy link
Copy Markdown

can we have these PR pull from master to be updated?

Copy link
Copy Markdown

@vincentchalamon vincentchalamon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @a-vasyliev for your contribution :-)
Please rebase from master.
@thomasbachem Is this project still maintained?

$saveFile = false;

if ($argc > 3) {
file_put_contents('php://stderr', 'Usage: php convert.php [-w] <file>' . "\n");
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'Usage: php array-converter.php…'


if ($isArraySyntax) {
// Replace "array" and the opening bracket (including preceeding whitespace) with "["
$replacements[] = array(
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe you could use short syntax array in this short syntax array converter? 😉

file_put_contents($filePath, $code);
} else {
print $code;
} No newline at end of file
Copy link
Copy Markdown

@vincentchalamon vincentchalamon Feb 17, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

EOF break line missing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants