Skip to content

Instantly share code, notes, and snippets.

View dj8yfo's full-sized avatar
💭
merciful respawns let you die with efficiency

dj8yf0μl dj8yfo

💭
merciful respawns let you die with efficiency
  • david protest the hero
View GitHub Profile
@sts10
sts10 / rust-command-line-utilities.markdown
Last active May 14, 2024 16:59
A curated list of command-line utilities written in Rust

A curated list of command-line utilities written in Rust

Note: I have moved this list to a proper repository. I'll leave this gist up, but it won't be updated. To submit an idea, open a PR on the repo.

Note that I have not tried all of these personally, and cannot and do not vouch for all of the tools listed here. In most cases, the descriptions here are copied directly from their code repos. Some may have been abandoned. Investigate before installing/using.

The ones I use regularly include: bat, dust, fd, fend, hyperfine, miniserve, ripgrep, just, cargo-audit and cargo-wipe.

  • atuin: "Magical shell history"
  • bandwhich: Terminal bandwidth utilization tool
from django.core.serializers import serialize
from django.http import HttpResponse
from .models import Movie
def movies_list(request):
queryset = Movie.objects.all()
content = serialize('json', queryset)
@okiwan
okiwan / deploy-insight.sh
Created November 14, 2018 19:14
Insight Debugger installation script for Bash on Ubuntu. Tested on 18.04LTS
#!/usr/bin/env /bin/bash
ORI_FOLDER=$(pwd)
TMP_FOLDER=$(mktemp -d)
LOG=$(mktemp)
APT_FLAGS="-y --reinstall"
GIT_FLAGS="-q --recursive"
INSIGHT="./configure --prefix=/usr/. --libdir=/usr/lib64 --disable-binutils --disable-elfcpp --disable-gas --disable-gold --disable-gprof --disable-ld --disable-rpath --disable-zlib --enable-sim --with-gdb-datadir=/usr/share/insight --with-jit-reader-dir=/usr/lib64/insight --with-separate-debug-dir='/usr/lib/debug' --with-expat --with-python --without-libunwind"
# Stop script at first error found
@nvgoldin
nvgoldin / asyncio_shutdown_loop.py
Created July 27, 2016 13:34
Python 3.5 asyncio - shutdown all tasks safely using signal handler
import signal
import functools
async def looping_task(loop, task_num):
try:
while True:
print('{0}:in looping_task'.format(task_num))
await asyncio.sleep(5.0, loop=loop)
except asyncio.CancelledError:
return "{0}: I was cancelled!".format(task_num)