P
P
Pavel Gogolinsky2015-06-25 21:15:29
git
Pavel Gogolinsky, 2015-06-25 21:15:29

What to do with modified packages in the vendor folder?

I have several libraries in the vendor folder. Some of them I had to edit. I added the function there, changed the variable there. At first, I had a vendor folder in .gitignore. But now I understand that it also needs to be committed. But this is bad, how then to update them? At me my changes will be superimposed. What do you do in this case?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
D', 2015-06-25
@gogolinsky

Touch the vendor folder? What for?
If you really want to change something, you can fork the project and change it yourself.
With updates, it will be a hassle, so you either need to make a pull-request to accept your changes, or manually merge your turnip and already update from it.

D
dmitriy, 2015-06-26
@dmitriylanets

you can redirect the library to a directory outside the vendor:
1.put it in src/
2.by writing
"autoload": {
"psr-4": {
"VendorName\\ProjectName\\": "src/ProjectName/"
}
},
3. will be updated
when, for example, the class new VendorName\ProjectName\ClassName()
is connected, the file taken from the vendor will be connected

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question