Closed sovetski closed 8 months ago
Great, thanks! That's merged into master now, https://github.com/BrianHenryIE/strauss/commit/a9bb376b70c3f0e1d2123bbb04d7f81dc9ca153a, and I added a test, https://github.com/BrianHenryIE/strauss/commit/6518699c8f96951a950f542a263d97a5f3fffb34. I also applied that removeUnusedServices
script to some older tests that I had marked as skip because they were previously too slow, https://github.com/BrianHenryIE/strauss/commit/5b905e107ddcbcac174fa93326f10ef7f670fe9a.
In general, edge cases like these need to be identified from errors before I can fix them. I think it would be better if this tool were using nikic/PHP-Parser, but the regex approach has gotten us this far. The currently open issues are more around dealing with Composer than the replacements themselves so it's not a priority to look into yet.
I have some other work in-progress so I'm not going to create a release immediately.
Hi,
My
composer.json
:I applied this suggestion which works as well, and it runs very quickly now.
But the problem is: The library does not prefix everything, in AWS example, before or after removing unused services, the problem is the same. It does not prefix this code (in:
/vendor-prefixed/aws/aws-sdk-php/src/S3/S3Client.php
):All other parts look fine, only this code is not prefixed, and I can not upload any files to AWS without this.
Any idea? I guess maybe it is because it starts with
\
?