Skip to content

Instantly share code, notes, and snippets.

@megclaypool
Last active November 22, 2024 23:08
Show Gist options
  • Select an option

  • Save megclaypool/c4ef29d6574a61056efb0f530bbf01ef to your computer and use it in GitHub Desktop.

Select an option

Save megclaypool/c4ef29d6574a61056efb0f530bbf01ef to your computer and use it in GitHub Desktop.
[Oh Fuck, I forgot my Password: Command Line Tools to the Rescue!] Note that these commands can also come in handy if your front-end is so messed up that you can't access the login screen...

Drush one-time login link for Drupal accounts

Holy crap, I never knew about this before, but this is awesome.

The command is drush uli

It's got options,

  • name for the username
  • uri to specify the url of the site (our weird setup requires us to specify the url of our site)

ex: drush uli --name=rootid --uri=http://midpen-openspace-d8.test

A window popped up that led straight to the user page, with its "reset password" fields! I'm using it on my local, so I'll need to redo if I pull the database from Pantheon, but I'm only doing this cause Jason's out of town so there aren't any changes to pull anyhow!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment