Skip to content

Instantly share code, notes, and snippets.

@lacostenycoder
Last active May 9, 2023 03:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lacostenycoder/5917a9d1619618805b9c8f912246016b to your computer and use it in GitHub Desktop.
Save lacostenycoder/5917a9d1619618805b9c8f912246016b to your computer and use it in GitHub Desktop.
Find your current Google Chrome Theme on the Web store (Mac only)
#!/usr/bin/env ruby
username = `whoami`.strip
filename = "/Users/#{username}/Library/Application\ Support/Google/Chrome/Default/Preferences"
data = File.read filename
string = data.split("theme")[1]
sha = string.split(/\W/)[7]
chrome_store_url = "https://chrome.google.com/webstore/detail/#{sha}"
puts chrome_store_url
`open #{chrome_store_url}`
@lacostenycoder
Copy link
Author

lacostenycoder commented Mar 3, 2018

You don't even need to download this. To run this script remotely just open a terminal and past this command:

ruby <(curl https://gist.githubusercontent.com/lacostenycoder/5917a9d1619618805b9c8f912246016b/raw/eb8ad0884ea3ef513633b0b5b78d7bdc351f955d/current_chrome_theme.rb)

@quang4ngo
Copy link

This doesn't seem to work anymore.

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