-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding PHP attributes #9555
Adding PHP attributes #9555
Conversation
I agree. We should be consistent about the order of the code examples and attributes should be the preferred choice nowadays. Looking at the code example you've updated, I also noticed that the annotation example (and consequently your new attribute example) don't import the |
@SenseException In Symfony docs there is a shorcut |
@derrabus: OK, done :-) Question about https://github.com/doctrine/orm/pull/9555/files#diff-239d9a128ce24a76e204d8b9821ce009ef5c7b16298d549165da9bc05d5d8f97R246
|
I'm done for the moment; please merge this, so I can see how it comes out. Then I'll continue. |
Please refrain from mentioning people in commit, it results in them receiving a notification every time that commit is cherry-picked here or there 🙏 |
stored in the metadata cache. If you're not using a metadata cache (not | ||
recommended!) then the XML driver is the fastest. | ||
|
||
Marking our ``Message`` class as an entity for Doctrine is straightforward: | ||
|
||
.. configuration-block:: | ||
|
||
.. code-block:: php | ||
.. code-block:: attribute |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As I commented on your commit where you mentioned me, isn't this going to break syntactic coloration?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, it's the same as I was using at https://www.doctrine-project.org/projects/doctrine-orm/en/2.11/reference/events.html#lifecycle-callbacks
Sorry about the mentioning! Somebody already told me that before - I hope I'll remember next time...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No worries, please reword that commit to make it go away.
How to do that?
git rebase -i origin/2.11.x
, assumingorigin
is a git remote that points to this repository, and not your fork. If you're not sure what your remotes are, rungit remote -vvv
, there should be your fork and the holy/reference/base/origin/whatever-you-call-it repository.- A window will show up with many lines, replace
pick
withreword
on the line corresponding to your commit - Close your editor, git should do its magic, and let you amend the commit message
- Use
git push --force
to overwrite what you already push. Don't forget the--force
option otherwise git will try to merge both things together.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, my "Git instructor"! :-) It looks like I succeeded.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, great job! My inbox thanks you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this is resolved? Could you please merge it then?
This is the first (small) step towards documenting enums - see doctrine#9304 (comment) I started reading the page from the top, and did some minor changes. Biggest change: If you agree, I'd continue adding php attributes to all code blocks.
Co-authored-by: Alexander M. Turek <[email protected]>
Co-authored-by: Alexander M. Turek <[email protected]>
Co-authored-by: Alexander M. Turek <[email protected]>
Co-authored-by: Alexander M. Turek <[email protected]>
…RM\Mapping\Column;`
@ThomasLandauer There's a Website: |
@SenseException Thanks, I now used it here too :-) |
Co-authored-by: Claudio Zizza <[email protected]>
Co-authored-by: Claudio Zizza <[email protected]>
* 2.12.x: Leverage MemcachedAdapter::isSupported() (doctrine#9578) Baseline Psalm errors caused by DBAL 3.3.3 (doctrine#9577) Make sure MemcachedAdapter is supported before tring to use it (doctrine#9574) Fixing `:doc:` link (doctrine#9569) Adding PHP attributes (doctrine#9555) Remove reference to removed class
@greg0ire This is the first (small) step towards documenting enums - see #9304 (comment)
I started reading the page from the top, and did some minor changes.
Biggest change: If you agree, I'd continue adding php attributes to all code blocks, and always mention it as first choice.