Skip to content

Instantly share code, notes, and snippets.

Avatar

Janik Vonrotz janikvonrotz

View GitHub Profile
View Pull all git projects.ps1
$gitUser = @(
"$Home\LocalDrive\GitHub",
"$Home\LocalDrive\GitLab",
"$Home\LocalDrive\GitHub_HaloCustomEdition",
"$Home\LocalDrive\GitHub_Hochschule-Luzern",
"$Home\LocalDrive\GitLab_Apoveda",
"$Home\LocalDrive\GitLab_Valora",
"$Home\LocalDrive\GitHub_Abilium",
"$Home\LocalDrive\GitHub_todo-md",
"$Home\LocalDrive\GitHub_Mint-System",
View Backup to external drive.md

Backupt to external drive

robocopy C:\Users\janik\LocalDrive D:\LocalDrive /MIR /R:1 /W:0 /XD node_modules

robocopy C:\Users\janik\Nextcloud D:\Nextcloud /MIR /R:1 /W:0

robocopy C:\Users\janik\Nextcloud2 D:\Nextcloud2 /MIR /R:1 /W:0

robocopy C:\Users\janik\janikv.cloud D:\janikv.cloud /MIR /R:1 /W:0

View Garmin Connect Weight.md
@janikvonrotz
janikvonrotz / Manually renew letsencrypt certificate.md
Created Apr 16, 2020
Manually renew letsencrypt certificate
View Manually renew letsencrypt certificate.md

Clone the letsencrypt cli.

git clone https://github.com/letsencrypt/letsencrypt
cd letsencrypt

Request a new certificate for your domain manually.

@janikvonrotz
janikvonrotz / Split-FileNamesByYearMonth.sh
Created Apr 7, 2020
Split file names into year and month folder
View Split-FileNamesByYearMonth.sh
for file in *; do
echo $file;
yearmonth=$(echo $file | grep -o '[0-9][0-9][0-9][0-9]-[0-9][0-9]')
newfilename=$(echo $file | grep -o '[0-9][0-9]-[a-z].*.md$')
mkdir $yearmonth
mv $file $yearmonth/$newfilename
done
@janikvonrotz
janikvonrotz / Collect-ImageMetadata.ps1
Last active Jul 20, 2020
Extract and transfrom metadata of all image files in a folder#powershell
View Collect-ImageMetadata.ps1
Function Get-FileMetaData {
Param([string[]]$folder)
foreach($sFolder in $folder)
{
$a = 0
$objShell = New-Object -ComObject Shell.Application
$objFolder = $objShell.namespace($sFolder)
foreach ($File in $objFolder.items())
{
View bookshelf.md

2020


Title: Wolkenbruchs waghalsiges Stelldichein mit der Spionin
Series: Wolkenbruch #2
Author: Thomas Meyer
Comment: Jewis customs from an exaggerated perspective. Amusing and provocative.
Rating: 7/10
ISBN: 3257070802
Finished: 15.11.2020

@janikvonrotz
janikvonrotz / map.geojson
Last active Jan 17, 2021
Places I've been to
View map.geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
View README.md
title author
Readme
Janik von Rotz

Knowledge

Logo

The knoweldge articles are stored in a strict structure. There are 7 top level folders:

@janikvonrotz
janikvonrotz / Convert-KeePassToPass.ps1
Last active Oct 20, 2019
Convert KeePass to Pass #KeePass #PowerShell
View Convert-KeePassToPass.ps1
[xml]$Content = Get-Content -Path "KeepassData.xml"
<#
Access the xml data:
Content.KeePassFile.Root.Group.Group.Entry[67].String[0].Value
#>
function Traverse-Tree ($Node, $ParentPath) {