Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
# DISCLAIMER: No warranty. Please read this script carefully before running and use at your own risk!
# Clears gsScrollPos cookies from chrome as temporary workaround for https://github.com/deanoemcke/thegreatsuspender/issues/537
# PSSQLite module required: https://www.powershellgallery.com/packages/PSSQLite/ - https://github.com/RamblingCookieMonster/PSSQLite
# WARNING: This WILL close any running chrome processes. This script will also need to be run as administrator to stop the chrome processes.
Import-Module PSSQLite
$null = Get-Process 'chrome' -ErrorAction SilentlyContinue | %{$_.CloseMainWindow()}
$DataSource = '~\AppData\Local\Google\Chrome\User Data\Default\Cookies'
$Query = "delete from cookies where name like 'gsScrollPos-%'"
Invoke-SqliteQuery -DataSource $DataSource -Query $Query
Start-Process 'chrome'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.