Skip to content

Instantly share code, notes, and snippets.

View gustybear's full-sized avatar

Yao Zheng gustybear

View GitHub Profile
@gustybear
gustybear / RemoveOneDriveDropboxNavigationPane.reg
Created January 26, 2020 06:14 — forked from AldoMX/RemoveOneDriveDropboxNavigationPane.reg
Remove OneDrive and Dropbox from the Navigation Pane in Windows 10
Windows Registry Editor Version 5.00
; Remove OneDrive
[HKEY_CLASSES_ROOT\CLSID\{018D5C66-4533-4307-9B53-224DE2ED1FE6}]
"System.IsPinnedToNameSpaceTree"=dword:00000000
; Remove Dropbox
[HKEY_CLASSES_ROOT\CLSID\{E31EA727-12ED-4702-820C-4B6445F28E1A}]
"System.IsPinnedToNamespaceTree"=dword:00000000
@gustybear
gustybear / delete_git_submodule.md
Created July 3, 2019 00:19 — forked from myusuf3/delete_git_submodule.md
How effectively delete a git submodule.

To remove a submodule you need to:

  • Delete the relevant section from the .gitmodules file.
  • Stage the .gitmodules changes git add .gitmodules
  • Delete the relevant section from .git/config.
  • Run git rm --cached path_to_submodule (no trailing slash).
  • Run rm -rf .git/modules/path_to_submodule (no trailing slash).
  • Commit git commit -m "Removed submodule "
  • Delete the now untracked submodule files rm -rf path_to_submodule
@gustybear
gustybear / arch_xps_install.sh
Created May 17, 2019 23:31 — forked from elbowz/Install Archlinux on XPS 13 9370 DualBoot with Windows
Install Archlinux on XPS 13 9370 DualBoot
# Resource
# https://gist.github.com/brammitch/281e9a2f3aca57ae4a333fc63732f602
# https://wiki.archlinux.org/index.php/Installation_guide
# https://wiki.archlinux.org/index.php/Dell_XPS_13_(9370)
# Switching from RAID to AHCI
# https://gist.github.com/chenxiaolong/4beec93c464639a19ad82eeccc828c63
# https://www.tenforums.com/drivers-hardware/15006-attn-ssd-owners-enabling-ahci-mode-after-windows-10-installation.html
# Turn off Windows fast boot
@gustybear
gustybear / Schedule-ChocoUpgradeAll.ps1
Last active June 2, 2018 06:07 — forked from dstreefkerk/Schedule-ChocoUpgradeAll.ps1
PowerShell script to create a scheduled task that runs a choco upgrade all at machine startup
# See if choco.exe is available. If not, stop execution
$chocoCmd = Get-Command -Name 'choco' -ErrorAction SilentlyContinue -WarningAction SilentlyContinue | Select-Object -ExpandProperty Source
if ($chocoCmd -eq $null) { break }
# Settings for the scheduled task
$taskAction = New-ScheduledTaskAction -Execute $chocoCmd -Argument 'upgrade all -y'
$taskTrigger = New-ScheduledTaskTrigger -Daily -At 11pm
$taskUserPrincipal = New-ScheduledTaskPrincipal -UserId 'SYSTEM'
$taskSettings = New-ScheduledTaskSettingsSet -Compatibility Win8