Skip to content

Instantly share code, notes, and snippets.

@xirixiz
xirixiz / Set up GitHub push with SSH keys.md
Last active April 18, 2024 01:32 — forked from developius/README.md
Set up GitHub push with SSH keys

SSH keypair setup for GitHub (or GitHub/GitLab/BitBucket, etc, etc)

Create a repo.

Make sure there is at least one file in it (even just the README.md)

Generate a SSH key pair (private/public):

ssh-keygen -t rsa -C "your_email@example.com"
@silgon
silgon / write_read_json.jl
Last active April 18, 2024 01:31
How to Read and Write JSON files in julia
import JSON
###################
### Write data ####
###################
# dictionary to write
dict1 = Dict("param1" => 1, "param2" => 2,
"dict" => Dict("d1"=>1.,"d2"=>1.,"d3"=>1.))
# pass data as a json string (how it shall be displayed in a file)
stringdata = JSON.json(dict1)
@Fevol
Fevol / LICENSE
Last active April 18, 2024 01:25
Embeddable CM Markdown Editor
Copyright 2024 Matthew Meyers, Fevol
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the β€œSoftware”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED β€œAS IS”, WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE US
@y-polek
y-polek / doze_mode_adb_commands.sh
Last active April 18, 2024 01:24
adb commands to test Doze mode
#! /bin/zsh
# Buttery powered state
adb shell dumpsys battery | grep powered
# Unplug battery
adb shell dumpsys battery unplug
# Reset battery
adb shell dumpsys battery reset
@bentman
bentman / Add-DevToMyWinServer.ps1
Last active April 18, 2024 01:21
Script to install Dev Tools on Windows Server 2022
<#
.SYNOPSIS
Script to install Dev Tools on Windows Server (tested on 2022)
.DESCRIPTION
Installs the following from multiple resources:
Microsoft.VCLibs v14.00 (github)
Microsoft.UI v2.7.3 (github)
winget-cli v1.6.2771 (github)
Microsoft pwsh.exe vCurrent (winget)
Microsoft.WindowsTerminal v1.18.2822.0 (github)
@dvf
dvf / change-codec.md
Last active April 18, 2024 01:13
Enable High Quality mode on your headphones (Updated for macOS Catalina)

If you're using a high-end bluetooth headset on your Macbook Pro it's likely your mac is using an audio codec which favors battery efficiency over high quality. This results in a drastic degradation of sound, the SBC codec is the likely culprit, read more about it here.

Find out what codec you're using

  1. Play a song on your headphones
  2. Option (βŒ₯) click the Bluetooth button at the top of your screen Inspect the Bluetooth Coded
  3. If you're using AAC or aptX, you can stop hereβ€”those are the highest quality codecs.

Change your codec to AAC or aptX

@DvdFalaschi
DvdFalaschi / gist:b9e4445f7278cf80b8c70c4d3d635d05
Last active April 18, 2024 01:12 — forked from rxaviers/gist:7360908
Lista completa de emojis para github markdown markup.

Pessoas

:bowtie: :bowtie: πŸ˜„ :smile: πŸ˜† :laughing:
😊 :blush: πŸ˜ƒ :smiley: ☺️ :relaxed:
😏 :smirk: 😍 :heart_eyes: 😘 :kissing_heart:
😚 :kissing_closed_eyes: 😳 :flushed: 😌 :relieved:
πŸ˜† :satisfied: 😁 :grin: πŸ˜‰ :wink:
😜 :stuck_out_tongue_winking_eye: 😝 :stuck_out_tongue_closed_eyes: πŸ˜€ :grinning:
πŸ˜— :kissing: πŸ˜™ :kissing_smiling_eyes: πŸ˜› :stuck_out_tongue:
@pukkandan
pukkandan / ytdlp_nest_comments.py
Last active April 18, 2024 01:12
Prettify and nest comments from yt-dlp's info.json file and write it to a new html/json file
#!/usr/bin/env python3
"""
SPDX-License-Identifier: MIT https://opensource.org/licenses/MIT
Copyright Β© 2021 pukkandan.ytdlp@gmail.com
* Input file is an info.json (with comments) that yt-dlp (https://github.com/yt-dlp/yt-dlp) wrote
* Change FIELDS according to your needs
@vasanthk
vasanthk / System Design.md
Last active April 18, 2024 01:09
System Design Cheatsheet

System Design Cheatsheet

Picking the right architecture = Picking the right battles + Managing trade-offs

Basic Steps

  1. Clarify and agree on the scope of the system
  • User cases (description of sequences of events that, taken together, lead to a system doing something useful)
    • Who is going to use it?
    • How are they going to use it?
@darekkay
darekkay / trakt-backup.php
Last active April 18, 2024 01:08
Trakt.tv backup script
<?php
/*
Backup script for trakt.tv (API v2).
Live demo: https://darekkay.com/blog/trakt-tv-backup/
*/
// create a Trakt app to get a client API key: http://docs.trakt.apiary.io/#introduction/create-an-app
$apikey = "CLIENT_API_KEY";