command composer require logger work properly
but after i do git status
show me
On branch master
Changes to be committed:
(use "git restore --staged <file>..." to unstage)
deleted: my_project_directory
Changes not staged for commit:
(use "git add <file>..." to update what will be committed)
(use "git restore <file>..." to discard changes in working directory)
modified: composer.json
modified: composer.lock
modified: config/bundles.php
modified: symfony.lock
then i write git add composer.json composer.lock config/bundles.php symfony.lock config/packages/monolog.yaml
and show me this error
warning: in the working copy of 'composer.json', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'composer.lock', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'config/bundles.php', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'symfony.lock', LF will be replaced by CRLF the next time Git touches it
warning: in the working copy of 'config/packages/monolog.yaml', LF will be replaced by CRLF the next time Git touches it
how i can fix this?
It's not really an error, it's more of a notification. It won't interrupt whatever it is you are doing.
Check in your console:
git config core.autocrlf
This will return either "false", "input" or "true"; "true" and "false" being the wrong values. Change it to "input" by typing:
git config --global core.autocrlf input
Replace --global by --local if you want to set it only for the active repository