Skip to content

Instantly share code, notes, and snippets.

View s3rgiosan's full-sized avatar

Sérgio Santos s3rgiosan

View GitHub Profile
@s3rgiosan
s3rgiosan / .macos
Last active March 27, 2024 06:32
macOS Setup
###############################################################################
# General UI/UX #
###############################################################################
HOSTNAME="s3rgiosan"
# Set computer name
sudo scutil --set ComputerName $HOSTNAME
sudo scutil --set HostName $HOSTNAME
sudo scutil --set LocalHostName $HOSTNAME
@s3rgiosan
s3rgiosan / terms.php
Last active December 16, 2022 16:10
A collection of helper functions for terms.
/**
* Returns the terms associated with the given object, hierarchically structured.
*
* @param array $object_id The ID of the object to retrieve.
* @param string|string[] $taxonomies The taxonomy names to retrieve terms from.
* @return array
*/
function get_object_hierarchical_terms( $object_id, $taxonomies ) {
// Retrieve the terms.
### Keybase proof
I hereby claim:
* I am s3rgiosan on github.
* I am s3rgiosan (https://keybase.io/s3rgiosan) on keybase.
* I have a public key whose fingerprint is F40C 4F8E B206 3360 1076 CA70 4FBF D42E 8A1D 167C
To claim this, I am signing this object: