* Add resolveFromConfigFile config option
Treats all paths as relative to the location of the config file, not
the current working directory of the process.
This commit just changes psalm, further commits will be needed to
apply the change to psalter and the LSP server.
* Copy asset xml files into project root for testing, delete during teardown
Needed since paths are now resolved relative to the position of the
file.
Not sure why I only saw a test failre for 1.xml - would have expected it
for all eight files.
* Fix following rebase
* Move psalm --init handly code above working directory setting code
If there's no psalm.xml yet we can't use the location of psalm.xml to
set our working directory
* Move Psalm version output code above working directory resolution
Working directory doesn't need to be known to output version constant
* Rely on new config file based working directory in end to end test
* Dont use rely on config dir for --alter - not currently working
* Fix code style error
* Add failing test for supporting config without `resolveFromConfigFile="true"`
* Don't treat config directory as a path to check
* Document resolveFromConfigFile setting
I'm guessing there's no difference between the two which means one needs 7.1 and the other only needs 7.0
Co-Authored-By: Bruce Weirdan <weirdan@gmail.com>
Previously a user of the phar distribution would have to invoke psalm as
`vendor/bin/psalm.phar`. This is different to the command given in
the psalm documentation, `vendor/bin/psalm`
I also copied all files from the psalm/phar repo into
assets/psalm-phar, so that development can be concentrated in this repo.
The travis-deploy-phar.sh should copy any changes made back into the
psalm/phar.git repo.
* Group changes
* Don’t worry about vars defined before exiting
* Fix issues with vars defined in conditionals
* Add failing test
* Only add failed reconciliation flag if nothing could be salvaged
* Avoid notice when removing clauses
* Improve handling of loops
* Fix evaluation of binary op expressions
* Remove unset vars from outer context after loop
* Ignore RedundantCondition in some more configs