5 echo "Usage: $0 <SMF database> <table prefix> <DB user> <password file> <SMF member ID>"
15 if [ "$(stat -c %A/%U ${dbpass})" != "-r--------/$(whoami)" ]
17 echo "Password file must have 400 permissions and must be owned by you! (And it must exist, by the way.)"
21 mysqlargs
="--user=${dbuser} --password=$(cat ${dbpass}) --database=${dbname} --default-character-set=utf8"
30 /usr
/sbin
/mysqld
--version
36 mysql
${mysqlargs} --batch --raw --skip-column-names --execute="SELECT id_member, member_name FROM ${dbpref}_members WHERE id_member = $smfidmember" |
sed 's+\t+ / +'
41 mysql
${mysqlargs} --execute="SELECT * FROM ${dbpref}_members WHERE id_member = $smfidmember\G"
44 echo Custom profile settings
:
46 mysql
${mysqlargs} --execute="SELECT * FROM ${dbpref}_themes WHERE id_member = $smfidmember\G"