Skip to content

Instantly share code, notes, and snippets.

View giridharvedula's full-sized avatar
🎯
Focusing

Giridhar Vedula giridharvedula

🎯
Focusing
View GitHub Profile
@giridharvedula
giridharvedula / del_vscode_mac.md
Created June 7, 2024 07:59 — forked from karansinghgit/del_vscode_mac.md
How to completely uninstall VSCode on Mac
  1. Close and Quit VSCode

  2. Remove VScode from Applications (just go to Finder -> Applications and move VSCode to Bin)

  3. Execute these commands in any order. The paths might be slightly different for you.

rm -fr ~/.vscode*
rm -fr ~/Library/Application\ Support/Code/

rm -fr ~/Library/Saved\ Application\ State/com.microsoft.VSCode.savedState/
rm -fr ~/Library/Preferences/com.microsoft.VSCode.helper.plist 
@giridharvedula
giridharvedula / Manage-ADUsers.ps1
Created October 17, 2023 16:28 — forked from 9to5IT/Manage-ADUsers.ps1
PowerShell: Cleanup Inactive AD User Accounts
Import-Module ActiveDirectory
# Set the number of days since last logon
$DaysInactive = 90
$InactiveDate = (Get-Date).Adddays(-($DaysInactive))
#-------------------------------
# FIND INACTIVE USERS
#-------------------------------
# Below are four options to find inactive users. Select the one that is most appropriate for your requirements:
@giridharvedula
giridharvedula / Manage-ADComputers.ps1
Created October 17, 2023 16:28 — forked from 9to5IT/Manage-ADComputers.ps1
PowerShell: Cleanup inactive AD computer objects
Import-Module ActiveDirectory
# Set the number of days since last logon
$DaysInactive = 90
$InactiveDate = (Get-Date).Adddays(-($DaysInactive))
#-------------------------------
# FIND INACTIVE COMPUTERS
#-------------------------------
# Below are three options to find inactive computers. Select the one that is most appropriate for your requirements:
@giridharvedula
giridharvedula / Manage-ADGroups.ps1
Created October 17, 2023 16:27 — forked from 9to5IT/Manage-ADGroups.ps1
PowerShell: Cleanup empty AD Groups
Import-Module ActiveDirectory
#-------------------------------
# FIND EMPTY GROUPS
#-------------------------------
# Get empty AD Groups within a specific OU
$Groups = Get-ADGroup -Filter { Members -notlike "*" } -SearchBase "OU=GROUPS,DC=testlab,DC=com" | Select-Object Name, GroupCategory, DistinguishedName
#-------------------------------
@giridharvedula
giridharvedula / Manage-ADOUs.ps1
Created October 17, 2023 16:27 — forked from 9to5IT/Manage-ADOUs.ps1
PowerShell: Cleanup empty AD OUs
Import-Module ActiveDirectory
#-------------------------------
# FIND EMPTY OUs
#-------------------------------
# Get empty AD Organizational Units
$OUs = Get-ADOrganizationalUnit -Filter * | ForEach-Object { If ( !( Get-ADObject -Filter * -SearchBase $_ -SearchScope OneLevel) ) { $_ } } | Select-Object Name, DistinguishedName
#-------------------------------