Skip to content

Instantly share code, notes, and snippets.

View elmarx's full-sized avatar
🐘
git rebase -i

Elmar Athmer elmarx

🐘
git rebase -i
View GitHub Profile
@hryniuk
hryniuk / pre-commit-cargo-fmt
Last active February 7, 2024 09:21
Git `pre-commit` hook that checks Rust code style with `cargo fmt`
#!/bin/bash
diff=$(cargo fmt -- --check)
result=$?
if [[ ${result} -ne 0 ]] ; then
cat <<\EOF
There are some code style issues, run `cargo fmt` first.
EOF
exit 1
@thwarted
thwarted / nodejs.spec
Created June 7, 2011 05:20 — forked from charles-dyfis-net/nodejs.spec
node.js spec for Fedora 14
#node is an already known package. node.js have dot in name, so "nodejs"
#is a better name
#some ideas are taken from
#http://blog.fpmurphy.com/2010/12/node-js-and-npm-on-fedora-14.html
Name: nodejs
Version: 0.4.8
Release: 0%{?dist}
Summary: JavaScript server-side network application development
Group: Development/Languages/Other
License: MIT
@elmarx
elmarx / django_gunicorn
Created December 23, 2010 14:35
init.d script for Debian GNU/Linux to run multiple Django instances, each in it's own virtualenv, with gunicorn.
#! /bin/sh
### BEGIN INIT INFO
# Provides: gunicorn_django
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Gunicorn WSGI server for django
# Description: This script starts a gunicorn instance for each django instance
### END INIT INFO