Skip to content

Instantly share code, notes, and snippets.

@BOAScripts
BOAScripts / WebCrawling_WikiFandom.py
Created April 27, 2023 17:08
Download One piece colr spreads from wiki fandom
#!/usr/bin/python3
'''
Downloading/Updating Color spreads of One Piece from the fandom site.
Usage:
python ./WebCrawling_wikiFandom.py
--> will download all the images in the current directory
python ./WebCrawling_wikiFandom.py -p "{PATH-TO-UPDATE}"
@BOAScripts
BOAScripts / List-LocalPs.py
Created November 29, 2022 12:24
[py] List local NIC/IPs - subprocess, ipconfig
# IMPORT
import subprocess
# DEF
def List_LocalIPs():
ipsList = [] #{"adapterName", "adapterIp"}
result=subprocess.run('ipconfig',stdout=subprocess.PIPE,text=True).stdout.lower()
for l in result.split('\n'):
if 'ethernet' in l or 'wireless' in l:
adapterName = l.replace(':','')
@BOAScripts
BOAScripts / Install-CaskaydiaCoveNF.ps1
Created October 31, 2022 15:38
Scripted installation of a NerdFont
# Setup tmp dir
$wrkDir = "$env:USERPROFILE\Desktop\TmpFonts"
New-Item $wrkDir -ItemType Directory | Out-Null
# Download
Write-Host -ForegroundColor DarkYellow "[I] Downloading fonts in $wrkDir"
$FontURL = "https://github.com/ryanoasis/nerd-fonts/releases/download/v2.2.2/CascadiaCode.zip"
$DestFont = "$wrkDir\CaskaydiaCoveNF.zip"
$ProgressPreference = 'SilentlyContinue'
Invoke-WebRequest -Uri $FontURL -OutFile $DestFont
$ProgressPreference = 'Continue'
@BOAScripts
BOAScripts / LatestPythonVer-Winget.ps1
Created October 30, 2022 16:53
Find id of latest Python version on winget
$Pythons3Search = winget search 'Python.3'
$PythonResults = $Pythons3Search[3..$Pythons3Search.Length]
[version]$ver ='3.0'
$node = ''
Foreach ($entry in $PythonResults) {
$entryVer = [version]$entry.replace(' ',';').split(';')[2]
$entryid = $entry.replace(' ',';').split(';')[1]
if ($ver -lt $entryVer ){
$ver = $entryVer
$node = $entryid