Skip to content

Instantly share code, notes, and snippets.

@shiftctrl-io
Last active November 10, 2016 07:37
Show Gist options
  • Save shiftctrl-io/f232b6de3d3393073e120db5b0beea45 to your computer and use it in GitHub Desktop.
Save shiftctrl-io/f232b6de3d3393073e120db5b0beea45 to your computer and use it in GitHub Desktop.
A Windows registry snippet which creates a non-removable Google Drive shortcut in the Windows Explorer sidebar similar to Dropbox and OneDrive.
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}]
@="Google Drive"
"System.IsPinnedToNamespaceTree"=dword:00000001
"SortOrderIndex"=dword:00000042
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\InProcServer32]
@=hex(2):25,00,53,00,59,00,53,00,54,00,45,00,4D,00,52,00,4F,00,4F,00,54,00,\
25,00,5C,00,73,00,79,00,73,00,74,00,65,00,6D,00,33,00,32,00,5C,00,73,00,68,\
00,65,00,6C,00,6C,00,33,00,32,00,2E,00,64,00,6C,00,6C,00,00,00
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\ShellFolder]
"FolderValueFlags"=dword:00000028
"Attributes"=dword:f080004d
[HKEY_CURRENT_USER\Software\Classes\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}]
@="Google Drive"
"System.IsPinnedToNamespaceTree"=dword:00000001
"SortOrderIndex"=dword:00000042
[HKEY_CURRENT_USER\Software\Classes\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\InProcServer32]
@=hex(2):25,00,53,00,59,00,53,00,54,00,45,00,4D,00,52,00,4F,00,4F,00,54,00,\
25,00,5C,00,73,00,79,00,73,00,74,00,65,00,6D,00,33,00,32,00,5C,00,73,00,68,\
00,65,00,6C,00,6C,00,33,00,32,00,2E,00,64,00,6C,00,6C,00,00,00
[HKEY_CURRENT_USER\Software\Classes\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\ShellFolder]
"FolderValueFlags"=dword:00000028
"Attributes"=dword:f080004d
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\DefaultIcon]
@="C:\\Program Files (x86)\\Google\\Drive\\googledrivesync.exe,0"
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\Instance]
"CLSID"="{0E5AAE11-A475-4c5b-AB00-C66DE400274E}"
[HKEY_CURRENT_USER\Software\Classes\Wow6432Node\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\Instance\InitPropertyBag]
"Attributes"=dword:00000011
"TargetFolderPath"="%USERPROFILE%\\Google Drive"
[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\HideDesktopIcons\NewStartPanel]
"{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}"=dword:00000001
[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Desktop\NameSpace\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}]
@="Google Drive"
[HKEY_CURRENT_USER\Software\Classes\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\DefaultIcon]
@="C:\\Program Files (x86)\\Google\\Drive\\googledrivesync.exe,0"
[HKEY_CURRENT_USER\Software\Classes\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\Instance]
"CLSID"="{0E5AAE11-A475-4c5b-AB00-C66DE400274E}"
[HKEY_CURRENT_USER\Software\Classes\CLSID\{81539FE6-33C7-4CE7-90C7-1C7B8F2F2D41}\Instance\InitPropertyBag]
"Attributes"=dword:00000011
"TargetFolderPath"="%USERPROFILE%\\Google Drive"

#Installation

  1. Backup registry

  2. Open GoogleDrive.reg in your favourite text editor.

  3. Update the %USERPROFILE% values for TargetFolderPath so that the final value is the full path to your Google Drive folder. Ensure that you use \\ in the folder path structure. (eg. "TargetFolderPath"="X:\\Google Drive")

  4. Save all changes

  5. Double-click GoogleDrive.reg to install and ensure you click yes when prompted.

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