Skip to content

Instantly share code, notes, and snippets.

@octlabs
octlabs / sort_array_by_key_weight.php
Last active November 4, 2020 10:31
sort array with defined key order
$arr = [
'x' => '1',
'foo' => 'me',
'y' => '2',
'bar' => '42',
'z' => '3',
];
/**
@octlabs
octlabs / centos_afpd.md
Last active September 2, 2024 02:31
Netatalk CentOS 8 network share

Setup MacOS AFP mounts with Apple timemachine for small office sharings on Linux CentOS 8

All users can access via AFP the same file share folders like sambe "force user, force group" using linux group s-bit and file and dir mask.

Also with cloud hub to store files local for faster access and not to have to store the data on all end devices.

Example shard directory for /vol1/shares/projects. /vol1/shares/customers

Replace MacOS perl with the latest brew version

Also fix error perl version 5.32.0 can't run /usr/bin/_shasum. for brew

/usr/bin/perl with /usr/local/bin/perl

MacOS 11.x Bug Sure

Warning, not particularly recommended