Skip to content

Instantly share code, notes, and snippets.

View auberginehill's full-sized avatar

auberginehill

View GitHub Profile
@auberginehill
auberginehill / gapps-config.txt
Last active March 28, 2021 16:27
Open GApps installer configuration file (Android)
### Open GApps installer Options
#
# File Name: .gapps-config (takes precedence, filename begins with a dot )
# gapps-config.txt
# .gapps-config-DEVICENAME Device-specific config files will take precedence over the non-device-specific ones.
# The DEVICENAME can be found in open_apps_log.txt or in the name of the ROM download.
# gapps-config-DEVICENAME.txt Device-specific config files will take precedence over the non-device-specific ones.
# The DEVICENAME can be found in open_apps_log.txt or in the name of the ROM download.
#
@auberginehill
auberginehill / Get-PowerShellSpecialFolders.ps1
Last active October 9, 2023 00:11
Retrieves Special Folders' names and corresponding paths along with the environment variable values in Windows PowerShell, and displays the generated commands used to get each value.
<#
Get-PowerShellSpecialFolders.ps1
#>
# Create an array that contains commands, how to get a particular special folder, and the values (paths) that they produce
$special_folders = @()
$names = [Environment+SpecialFolder]::GetNames([Environment+SpecialFolder]) | Sort
ForEach ($name in $names) {
@auberginehill
auberginehill / Rename-Files.ps1
Last active December 30, 2022 22:51
A Windows PowerShell script for renaming files.
<#
Rename-Files.ps1
#>
# Find all wmv-files with a string "oldstring" and replace "oldstring" with "newstring" in the filename
Get-ChildItem *.wmv -Filter "*oldstring*" | ForEach { Rename-Item $_ -NewName $_.Name.Replace("oldstring","newstring") }
# Change the file extension of all .jpeg files to .jpg
@auberginehill
auberginehill / Get-TimeDifference.ps1
Last active February 23, 2017 16:21
Examples of time difference calculations (between now and an arbitrary future date) and other date and time related tasks in Windows PowerShell.
<#
Get-TimeDifference.ps1
Windows PowerShell: For a more comfortable reading experience, please type
help ./Get-TimeDifference -Full
#>