Created
October 28, 2013 10:39
-
-
Save svenvarkel/7194716 to your computer and use it in GitHub Desktop.
This is a useful oneliner for reading Magento database password from local.xml in command line
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# run in your app/etc folder | |
grep -o -P "<password><\!\[CDATA\[([\w]*)\]\]><\/password>" local.xml | sed -e 's|<password><\!\[CDATA\[||g' | sed -e 's|\]\]></password>||g' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment