Skip to content

Instantly share code, notes, and snippets.

View stonecharioteer's full-sized avatar

Vinay Keerthi stonecharioteer

View GitHub Profile
@reegnz
reegnz / README.md
Last active April 23, 2024 18:36
Implementing a jq REPL with fzf

Implementing a jq REPL with fzf

Update: I created jq-zsh-plugin that does this.

One of my favourite tools of my trade is jq. It essentially enables you to process json streams with the same power that sed, awk and grep provide you with for editing line-based formats (csv, tsv, etc.).

Another one of my favourite tools is fzf.

@tirkarthi
tirkarthi / py3_issues.md
Last active February 18, 2020 16:21
Python 3.8 and 3.9 issues

Do take one issue per person to help others :) Also checkout Fedora tracker for more easy issues : https://bugzilla.redhat.com/show_bug.cgi?id=1785415 . I tried to mark the issues complete but it's more maintenance so sorry if the issue is fixed or already has a PR and is not updated here.

git_current_branch () {
local ref
ref=$(command git symbolic-ref --quiet HEAD 2> /dev/null)
local ret=$?
if [[ $ret != 0 ]]
then
[[ $ret == 128 ]] && return
ref=$(command git rev-parse --short HEAD 2> /dev/null) || return
fi
echo ${ref#refs/heads/}
@mohanpedala
mohanpedala / bash_strict_mode.md
Last active June 29, 2024 04:08
set -e, -u, -o, -x pipefail explanation
@jtpio
jtpio / app.py
Created January 24, 2018 23:17
Dash URL State example
import dash
import dash_core_components as dcc
import dash_html_components as html
from urllib.parse import urlparse, parse_qsl, urlencode
from dash.dependencies import Input, Output
app = dash.Dash()
app.config.suppress_callback_exceptions = True
@kingspp
kingspp / logging.py
Created April 22, 2017 07:14
Python Comprehensive Logging using YAML Configuration
import os
import yaml
import logging.config
import logging
import coloredlogs
def setup_logging(default_path='logging.yaml', default_level=logging.INFO, env_key='LOG_CFG'):
"""
| **@author:** Prathyush SP
| Logging Setup
@computerality
computerality / gist:3e0bc104cd216bf0f03f8d3aa8fbf081
Last active December 12, 2020 14:30
iOS Security Guide changes for iOS 10 from March 2017
These are additions or notable revisions in the iOS Security Guide
Document Revision History Summary Updated for iOS 10
• System Security
• Data protection classes
• Security Certifications and programs
• HomeKit, ReplayKit, SiriKit
• Apple Watch
• Wi-Fi,VPN
• Single Sign-on
• Apple Pay, Paying with Apple Pay on the web
@buckett
buckett / clean-docker.sh
Created May 19, 2015 11:02
Cleans out old docker images and containers.
#!/bin/bash
# Clean all exited containers
docker ps -qaf status=exited | xargs docker rm
# Remove all unused images
docker images -f dangling=true -q | xargs docker rmi
@kwmiebach
kwmiebach / pytest.md
Last active June 4, 2024 06:29 — forked from amatellanes/pytest.sh
pytest cheat sheet

Usage

(Create a symlink pytest for py.test)

pytest [options] [file_or_dir] [file_or_dir] ...

Help:

@willurd
willurd / web-servers.md
Last active June 28, 2024 12:38
Big list of http static server one-liners

Each of these commands will run an ad hoc http static server in your current (or specified) directory, available at http://localhost:8000. Use this power wisely.

Discussion on reddit.

Python 2.x

$ python -m SimpleHTTPServer 8000