PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Tuesday, February 15, 2022

[FIXED] Is there a way to change name of generated by assets:install symbolic link in symfony?

 February 15, 2022     assets, php, symfony, symlink     No comments   

Issue

I see by default there are generated links with name bundle/bundlename when using assets:install command. Is there a way to change this name?


Solution

You can inspect the current code that is used in Symfony's repository. To define the folder per bundle, a single line is used:

$assetDir = preg_replace('/bundle$/', '', strtolower($bundle->getName()));

There are no parts to hook into this generation from the outside, neither defined in the command itself (such that you could decorate the command) nor in the bundle's definition (such that you would gain more freedom to generate a folder name within the bundle, that is not bound to the getName method).



Answered By - Nico Haase
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing