Skip to content

Instantly share code, notes, and snippets.

View nunofgs's full-sized avatar

Nuno Sousa nunofgs

  • Customer.io
  • Braga, Portugal
  • X @nunofgs
View GitHub Profile
@christianparpart
christianparpart / terminal-synchronized-output.md
Last active May 4, 2024 01:00
Terminal Spec: Synchronized Output

Synchronized Output

Synchronized output is merely implementing the feature as inspired by iTerm2 synchronized output, except that it's not using the rare DCS but rather the well known SM ? and RM ?. iTerm2 has now also adopted to use the new syntax instead of using DCS.

Semantics

When rendering the screen of the terminal, the Emulator usually iterates through each visible grid cell and renders its current state. With applications updating the screen a at higher frequency this can cause tearing.

This mode attempts to mitigate that.

@hunterjm
hunterjm / frigate_notification.yaml
Last active April 27, 2024 23:54
Frigate Notification Blueprint
blueprint:
name: Frigate Notification
description: |
## Frigate Mobile App Notification
This blueprint will send a notification to your device when a Frigate event for the selected camera is fired. The notification will initially include the thumbnail of the detection, but will update to include actionable notifications allowing you to view the saved clip/snapshot when available, or silence the notification for a configurable amount of time.
With this blueprint, you may send the notification to multiple devices by leaving "Device" blank and instead use a [notification group][1].
### Required entities:
@jsorrell
jsorrell / AuthyCodes.md
Last active February 16, 2023 22:22
Export TOTP secrets from Authy to use in another authenticator

Migrating from Authy to another authenticator

Last tested on Authy 2.5.0
Thanks to Guillaume's Gist and @puddly's comment

To use Authy's special 7 Digit TOTP's, ensure that they are supported by your authenticator

Instructions

  1. Ensure Google Chrome or Chromium is installed.
  2. Install Authy desktop app from the Chrome web store.
  3. Open Authy desktop app enter backup password to ensure all account TOTP's are visible.
@boneskull
boneskull / README.md
Last active April 10, 2024 12:47
example of how to debug mocha v4 if hanging

Here's an example of how to debug Mocha v4 if it hangs.

Ensure you're using a Node.js 8 or newer (or any version with async_hooks support).

If you run your test, you'll notice it hangs:

$ mocha test.js
@pierrejoubert73
pierrejoubert73 / markdown-details-collapsible.md
Last active May 2, 2024 16:19
How to add a collapsible section in markdown.

How to add a collapsible section in markdown

1. Example

Click me

Heading

  1. Foo
  2. Bar
    • Baz
  • Qux
@scottopell
scottopell / fix_exfat_drive.md
Last active April 30, 2024 22:46
Fix corrupted exFAT disk macOS/OSX

exFAT support on macOS seems to have some bugs because my external drives with exFAT formatting will randomly get corrupted.

Disk Utility is unable to repair this at first, but the fix is this:

  1. Use diskutil list to find the right drive id.
  2. You want the id under the IDENTIFIER column, it should look like disk1s1
  3. Run sudo fsck_exfat -d <id from above>. eg sudo fsck_exfat -d disk1s3
  4. -d is debug so you'll see all your files output as they're processed.
  5. Answer YES if it gives you the prompt Main boot region needs to be updated. Yes/No?
@0xjac
0xjac / private_fork.md
Last active May 8, 2024 00:17
Create a private fork of a public repository

The repository for the assignment is public and Github does not allow the creation of private forks for public repositories.

The correct way of creating a private frok by duplicating the repo is documented here.

For this assignment the commands are:

  1. Create a bare clone of the repository. (This is temporary and will be removed so just do it wherever.)

git clone --bare git@github.com:usi-systems/easytrace.git

@janeczku
janeczku / cloud-config.yaml
Last active June 7, 2018 13:57
RancherOS iPXE boot script and cloud-config. Ramdisk based deployment with persistent storage on disk. Configures private IP on eth1 from EC2 metadata.
#cloud-config
hostname: rancher-os
ssh_authorized_keys:
- ssh-rsa REPLACE_WITH_PUBLIC_SSH_KEY
rancher:
debug: false
cloud_init:
datasources:
- ec2
state:
@deltaepsilon
deltaepsilon / AssetsClient.coffee
Created December 30, 2012 16:43
Part of my Meteor asset upload client code. This handle the drag and drop events and calls the createAsset method.
Template.assetUpload.events(
'drop #asset-upload-dropzone': (e) ->
e.stop()
$(e.target).removeClass 'dropzone-hover'
new AssetUpload(e)
'dragenter #asset-upload-dropzone': (e) ->
e.stop()
$(e.target).addClass 'dropzone-hover'
@albrow
albrow / Rakefile
Last active December 10, 2015 05:08
An excerpt from the Rakefile I use to deploy my blog. http://blog.alexbrowne.info
# ...
desc "Deploy website to s3/cloudfront via aws-sdk"
task :s3_cloudfront => [:generate, :minify, :gzip, :compress_images] do
puts "=================================================="
puts " Deploying to Amazon S3 & CloudFront"
puts "=================================================="
# setup the aws_deploy_tools object
config = YAML::load( File.open("_config.yml"))