Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[FrameworkBundle] Replace var_export with VarExporter to use array short syntax in secrets list files#41795

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

@alexandre-daubois
Copy link
Member

QA
Branch?4.4
Bug fix?yes
New feature?no
Deprecations?no
TicketsN/A
LicenseMIT
Doc PRN/A

I've been using secrets a lot lately. Unfortunately, command exports the{env}.list.php with the "old" array syntax usingarray(), and writingnull in uppercase.

This results in tedious situations with PHP CS Fixer (for example) rewriting the whole file to restore the modern syntax, each time we add a secret.

The Sodium vault currently usesvar_export. I suggest using Symfony VarExporter, which does the work just fine. It adds a dependency to the FrameworkBundle, but it is a cleaner way to do it rather than usingthis type of hack IMO.

"symfony/finder":"^3.4|^4.0|^5.0",
"symfony/routing":"^4.4.12|^5.1.4"
"symfony/routing":"^4.4.12|^5.1.4",
"symfony/var-exporter":"^4.4|^5.0"

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

can be removed actually: var-exporter is already a transitive dep via symfony/cache and that won't change

Copy link
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

Removed, thanks for the info!

@derrabus
Copy link
Member

Thank you@alexandre-daubois.

@derrabusderrabus merged commit124ecf0 intosymfony:4.4Jun 22, 2021
@alexandre-dauboisalexandre-daubois deleted the fix-vault-list-format branchJune 23, 2021 04:36
This was referencedJun 30, 2021
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@nicolas-grekasnicolas-grekasnicolas-grekas approved these changes

@derrabusderrabusderrabus approved these changes

Assignees

No one assigned

Projects

None yet

Milestone

4.4

Development

Successfully merging this pull request may close these issues.

4 participants

@alexandre-daubois@derrabus@nicolas-grekas@carsonbot

[8]ページ先頭

©2009-2025 Movatter.jp