Skip to content

Instantly share code, notes, and snippets.

View tsvetkovv's full-sized avatar

Viktor Tsvetkov tsvetkovv

View GitHub Profile
@tsvetkovv
tsvetkovv / immich-albums-from-the-folders.js
Last active December 31, 2024 18:50
Create Immich albums from the folder structure
/**
* Immich Album Creator Script
*
* This script automatically creates albums in Immich based on your folder structure.
*
* Expected folder structure:
* mnt/originals/{year}/{month}/{album-name}
*
* Examples of valid paths:
* - mnt/originals/2023/05/2023-05-01-Birthday
@tsvetkovv
tsvetkovv / static-hostnames.ros
Last active January 16, 2024 22:42
routeros mikrotik set static hostname for DHCP lease (whiltelist)
# RouterOS 7.11.2
:global hostnames {"hostname1"; "hostname2"};
:global domain "home";
# Function to check if hostname is in the array
:local isInArray do={
:local result false;
:foreach item in=$hostnames do={