Skip to content

Instantly share code, notes, and snippets.

View sergiitk's full-sized avatar
🚀
Back to work

Sergii Tkachenko sergiitk

🚀
Back to work
View GitHub Profile
@drfloob
drfloob / is_branch_merged.sh
Last active November 18, 2021 22:36
A script to check if branch A has been squash-merged to branch B (default: master) by evaluating diffs of branch A vs diff of all commits on branch B
#!/bin/bash
set -e
function cleanup {
rm $DIFF_FILE $TMPFILE
}
trap cleanup EXIT
@ejona86
ejona86 / backport.sh
Last active June 17, 2022 19:25
Custom backport script for grpc-java
#!/bin/bash
# Copyright 2020 The gRPC Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
; acceleration_enabled = {acceleration_enabled}
; acceleration_infill = {acceleration_infill}
; acceleration_ironing = {acceleration_ironing}
; acceleration_layer_0 = {acceleration_layer_0}
; acceleration_prime_tower = {acceleration_prime_tower}
; acceleration_print = {acceleration_print}
; acceleration_print_layer_0 = {acceleration_print_layer_0}
; acceleration_roofing = {acceleration_roofing}
; acceleration_skirt_brim = {acceleration_skirt_brim}
; acceleration_support = {acceleration_support}
@RobSpectre
RobSpectre / app.py
Created April 27, 2017 21:49
Example of using Celery for Quasar Queue
from flask import Flask
from flask import request
from tasks import store_db
app = Flask(__name__)
@app.route('/blink', methods=['GET', 'POST'])
def blink():
@scottstanfield
scottstanfield / osx-defaults.sh
Created July 18, 2016 03:40
Lots of OSX defaults
#!/bin/sh
# 90% from http://mths.be/osx
# ask for admin password upfront
sudo -v
# Keep-alive: update existing `sudo` time stamp until `.osx` has finished
while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null &
@NOTtheMessiah
NOTtheMessiah / Dr. Krieger's ASCII Bound.ipynb
Created April 30, 2016 05:21
Clue from the Archer Scavenger Hunt
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@vasanthk
vasanthk / System Design.md
Last active July 4, 2024 15: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?
@stephenlb
stephenlb / animated-gif.md
Last active October 31, 2020 22:57
DIY How to make your own HD Animated GIF Generator

HD Animated GIF Generator

You can make your own HD animated GIF generator.
Follow along with these commands to get started.

HD Animated GIF Generator

git clone git://source.ffmpeg.org/ffmpeg.git
cd ffmpeg
@rmondello
rmondello / gist:b933231b1fcc83a7db0b
Last active April 5, 2024 07:10
Exporting (iCloud) Keychain and Safari credentials to a CSV file

Exporting (iCloud) Keychain and Safari credentials to a CSV file

Update (October 2021)

Exporting password + one-time code data from iCloud Keychain is now officially supported in macOS Monterey and Safari 15 (for Monterey, Big Sur, and Catalina). You can access it in the Password Manager’s “gear” icon (System Preferences > Passwords on Monterey, and Safari > Passwords everywhere else), or via the File > Export > Passwords... menu item). You shouldn't need to hack up your own exporter anymore.

Original, Obsolete Content (2014)

After my dad died, I wanted to be able to have access any of his online accounts going forward. My dad was a Safari user and used iCloud Keychain to sync his credentials across his devices. I don’t want to have to keep an OS X user account around just to access his accounts, so I wanted to export his credentials to a portable file.

@jimschubert
jimschubert / README.md
Last active October 30, 2023 01:33
prepare-commit-msg which adds branch name and description to the end of a commit message (git hook)

Installation

To install globally, copy prepare-commit-msg to /usr/local/share/git-core/templates/hooks and execute:

chmod +x /usr/local/share/git-core/templates/hooks/prepare-commit-msg

To install per-repository, copy prepare-commit-msg to /path/to/repo/.git/hooks/prepare-commit-msg and mark it as executable.