Skip to content

Instantly share code, notes, and snippets.

View tony-sol's full-sized avatar
πŸ«₯
total burnout

Tony Soloveyv tony-sol

πŸ«₯
total burnout
View GitHub Profile
@arianvp
arianvp / SSH_MACOS_SECURE_ENCLAVES.md
Last active June 27, 2026 12:16
Native Secure Enclaved backed ssh keys on MacOS

Native Secure Enclave backed ssh keys on MacOS

It turns out that MacOS Tahoe can generate and use secure-enclave backed SSH keys! This replaces projects like https://github.com/maxgoedjen/secretive

There is a shared library /usr/lib/ssh-keychain.dylib that traditionally has been used to add smartcard support to ssh by implementing PKCS11Provider interface. However since recently it also implements SecurityKeyProivder which supports loading keys directly from the secure enclave! SecurityKeyProvider is what is normally used to talk to FIDO2 devices (e.g. libfido2 can be used to talk to your Yubikey). However you can now use it to talk to your Secure Enclave instead!

-- Summary: get multiple file contents into one and write it back
-- Config: configuration should be done directly inside source code. This one is very niche so I won't make it into a plugin
-- Default it will find all file (exclude hidden files, take a look at line 47) in the current directory
-- If needed specific file pattern then you can pass pattern into the read() function like: require'onefiler'.read("/*.zig")
-- Change M.filename_deco to suit your file type, I recommend make it a comment line
-- It will write to any file in the onefile if match, so be careful before write
-- Usage:
-- Keymap: you can assign keymap for it
@moreati
moreati / ansible_playbook_keywords_table.rst
Last active March 14, 2026 17:31
Table showing Ansible playbook keywords that can be used at play, role, block, or task level

Generated using development version of Ansible on 15 Sep 2024. Details may differ from released versions.

@saharshbhansali
saharshbhansali / ObsidianMarkdownGuide.md
Last active May 11, 2026 13:44
Markdown Formatting Guide for Obsidian. Import this gist as a file into your Obsidian Vault to view it and to test new themes. Certain community plugins are required for a few features.

Markdown Formatting Guide for Obsidian

Learn how to apply basic formatting to your Obsidian notes, usingΒ Markdown. Import this as a note into your Obsidian Vault to view it and to test new themes. Certain community plugins are required for a few features.


Basic Formatting Syntax


Paragraphs

To create paragraphs, use a blank line to separate one or more lines of text.

using namespace System.Management.Automation
using namespace System.Management.Automation.Language
if ($host.Name -eq 'ConsoleHost')
{
Import-Module PSReadLine
}
#Import-Module PSColors
#Import-Module posh-git
Import-Module -Name Terminal-Icons
@vancluever
vancluever / macos-big-sur-ssh-agent-local-no-disable-sip.md
Last active October 19, 2025 11:05
Run SSH Agent w/Modified Options (MacOS Big Sur, No Homebrew, No SIP Modification)

Run SSH Agent w/Modified Options (MacOS Big Sur, No Homebrew, No SIP Modification)

The following will show you how you can modify the startup options of the SSH agent supplied by MacOS in a non-invasive way. This can be useful for doing things like setting a key lifetime, which can then be used with AddKeysToAgent in your ~/.ssh/config to automate the timing out of saved keys. This ensures that your passphrase is re-asked for periodically without having to shutdown, re-log, or having it actually persisted in keychain, the latter being almost as bad as having no passphrase at all, given that simply being logged in is generally enough to then use the key.

This method does not modify the system-installed SSH agent service (com.openssh.ssh-agent), but rather duplicates its functionality into a user-installed launch agent where we can then modify the options. Modifying the system-installed service is becoming increasingly harder to do; SIP generally protects

ZSH CheatSheet

This is a cheat sheet for how to perform various actions to ZSH, which can be tricky to find on the web as the syntax is not intuitive and it is generally not very well-documented.

Strings

Description Syntax
Get the length of a string ${#VARNAME}
Get a single character ${VARNAME[index]}
@roalcantara
roalcantara / XDG.cheat-sheet.md
Last active June 23, 2026 05:24
XDG cheat sheet

XDG - Base Directory Specification (extended)

Directories

Base

The intended use-case for BaseDirectories is to query the paths of user-invisible standard directories that have been defined according to the conventions of the operating system the library is running on.