Skip to content

Instantly share code, notes, and snippets.

View bartvdbraak's full-sized avatar
🎈
creating and contributing

Bart van der Braak bartvdbraak

🎈
creating and contributing
View GitHub Profile
@bartvdbraak
bartvdbraak / logseq-ios.md
Created July 29, 2024 00:24
Sync Logseq on iOS with `git` and A-Shell

Set up git over SSH on iOS

  1. Install A-Shell on iOS
  2. Create an SSH key on device
ssh-keygen -t ecdsa -N "" -f ~/Documents/.ssh/id_ecdsa
  1. Copy the public key and add to where your remote repository is (GitHub, Gitlab, Gitea, etc.)
cat ~/Documents/.ssh/id_ecdsa.pub
@bartvdbraak
bartvdbraak / get-bitlocker-description-percentage.ps1
Created June 9, 2024 22:41
Powershell commands to get BitLocker Encryption/Decryption status
while (1) {Get-BitLockerVolume -MountPoint "C:" | Select-Object EncryptionPercentage; sleep 5}
@bartvdbraak
bartvdbraak / hip-5.7-windows-install.ps1
Last active May 27, 2024 12:45
Windows commands for installing HIP 5.7 on Windows
Invoke-WebRequest `
-Uri "https://download.amd.com/developer/eula/rocm-hub/AMD-Software-PRO-Edition-23.Q4-Win10-Win11-For-HIP.exe" `
-OutFile "~\Downloads\Setup.exe"
Start-Process ~\Downloads\Setup.exe -ArgumentList '-install','-log',"${env:USERPROFILE}\installer_log.txt" -NoNewWindow -Wait
@bartvdbraak
bartvdbraak / bootstrap-rockylinux8-blender-compile.sh
Last active May 24, 2024 15:39
Rocky Linux 8 commands to bootstrap for Blender compilation
curl https://projects.blender.org/blender/blender/raw/branch/main/build_files/build_environment/linux/linux_rocky8_setup.sh -o linux_rocky8_setup.sh
chmod +x linux_rocky8_setup.sh
sudo ./linux_rocky8_setup.sh
echo "source scl_source enable gcc-toolset-11" | sudo tee -a /etc/profile
@bartvdbraak
bartvdbraak / bootstrap-windows-blender-compile.ps1
Last active May 24, 2024 12:35
Windows commands to bootstrap for Blender compilation
Add-AppPackage -path "https://cdn.winget.microsoft.com/cache/source.msix."
winget install Microsoft.VisualStudio.2022.Community --override "--add ProductLang En-us --add Microsoft.VisualStudio.Workload.NativeDesktop --includeRecommended"
winget install Git.Git
winget install Kitware.CMake
{"label":"lighthouse","message":"99","schemaVersion":1,"color":"4c1","namedLogo":"Lighthouse"}
@bartvdbraak
bartvdbraak / backup-wwwroot.py
Created January 30, 2024 20:07
(unfinished) Download wwwroot of Linux Web App on Azure using ssh and tar
import os
import sys
import time
import subprocess
import re
import paramiko
from paramiko import SSHClient, AutoAddPolicy
REMOTE_FILE_OUTPUT = "/home/site/wwwroot.tar"
{"label":"lighthouse","message":"98","schemaVersion":1,"color":"4c1","namedLogo":"Lighthouse"}
@bartvdbraak
bartvdbraak / remove-pipeline-retention.ps1
Created June 26, 2023 02:34
This PowerShell script deletes a specified Azure DevOps pipeline and its builds.
param (
[Parameter(Mandatory=$true)]
[string]$PersonalToken,
[Parameter(Mandatory=$true)]
[string]$Organization,
[Parameter(Mandatory=$true)]
[string]$Project
)
@bartvdbraak
bartvdbraak / monitor-ip-changes.sh
Created June 20, 2023 14:33
Quick one-liner that will print any changes of the public IP of your machine
while true; do result=$(curl -s ifconfig.wearetriple.com); if [[ "$result" != "$previous_result" ]]; then echo "$(date) $result"; previous_result=$result; fi; sleep 1; done