Skip to content

Instantly share code, notes, and snippets.

View p7k's full-sized avatar
🏠
Working from home

Pavel Katsev p7k

🏠
Working from home
View GitHub Profile
@hshoff
hshoff / Blackbored.xml
Created February 1, 2011 22:21
Textmate's Blackboard color theme cloned (kind-of) for RubyMine.
<?xml version="1.0" encoding="UTF-8"?>
<scheme name="Blackbored" version="1" parent_scheme="Default">
<option name="LINE_SPACING" value="1.25" />
<option name="EDITOR_FONT_SIZE" value="12" />
<option name="EDITOR_FONT_NAME" value="Monaco" />
<colors>
<option name="ANNOTATIONS_COLOR" value="3e83e7" />
<option name="CARET_COLOR" value="" />
<option name="CARET_ROW_COLOR" value="40436" />
<option name="CONSOLE_BACKGROUND_KEY" value="0" />
@jacobh
jacobh / photos.models.py
Created November 6, 2011 10:17
django-imagekit
from django.db import models
from django.contrib.auth.models import User
from imagekit.models import ImageSpec
from imagekit.processors import resize, Adjust
from django.db.models.signals import post_save
from django.dispatch import receiver
from celery.task import task
from celery.execute import send_task
@peteonrails
peteonrails / geos
Created November 10, 2011 22:34
Updating the Homebrew formula for geos, when Mac OS X Lion complains about LLVM / gcc-4.2
require 'formula'
class Geos < Formula
url 'http://download.osgeo.org/geos/geos-3.3.1.tar.bz2'
homepage 'http://trac.osgeo.org/geos/'
md5 'b1ceefe205c9ee520b99f2b072c345f7'
def skip_clean? path
path.extname == '.la'
end
@rozza
rozza / gist:1372780
Created November 17, 2011 09:28
Encoder for MongoEngine Object
import datetime
import simplejson
from pymongo.dbref import DBRef
from pymongo.objectid import ObjectId
class MongoEngineEncoder(simplejson.JSONEncoder):
"""Handles Encoding of ObjectId's"""
@agnoster
agnoster / README.md
Last active March 14, 2024 15:54
My ZSH Theme

agnoster.zsh-theme

A ZSH theme optimized for people who use:

  • Solarized
  • Git
  • Unicode-compatible fonts and terminals (I use iTerm2 + Menlo)

For Mac users, I highly recommend iTerm 2 + Solarized Dark

@burke
burke / remotepaste.md
Last active September 26, 2023 11:04
This sets up keybindings in tmux that allow you to copy/paste to/from your OS X clipboard from tmux running inside an SSH connection to a remote host. Partially borrowed from http://seancoates.com/blogs/remote-pbcopy

Local (OS X) Side

~/Library/LaunchAgents/pbcopy.plist

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
     <key>Label</key>
     <string>localhost.pbcopy</string>
@t-io
t-io / osx_install.sh
Last active October 22, 2023 13:04
Install most of my Apps with homebrew & cask
#!/bin/sh
echo Install all AppStore Apps at first!
# no solution to automate AppStore installs
read -p "Press any key to continue... " -n1 -s
echo '\n'
echo Install and Set San Francisco as System Font
ruby -e "$(curl -fsSL https://raw.github.com/wellsriley/YosemiteSanFranciscoFont/master/install)"
echo Install Homebrew, Postgres, wget and cask
ruby -e "$(curl -fsSL https://raw.github.com/Homebrew/homebrew/go/install)"
@markjlorenz
markjlorenz / mutt_notes.markdown
Last active July 25, 2021 18:16
Notes on getting Mutt running on OSX
  • brew install mutt
  • setup an app password for mutt in gmail
  • setup an app password for imap_notifier in gmail
  • brew install terminal-notifier terminal-notifier
  • gem install imap_notifier imap_notifier
  • brew install urlview
  • brew install w3m (links would be OK too)
  • Install pandoc to author in markdown and send as HTML

~/.muttrc

@rklaehn
rklaehn / Client example
Last active June 8, 2020 12:38
akka http file server
package akkahttptest
import akka.http.Http
import akka.stream.ActorFlowMaterializer
import akka.actor.ActorSystem
import akka.stream.scaladsl.{Sink, Source}
import akka.http.model._
object TestClient extends App {
@martijnvermaat
martijnvermaat / import.sh
Last active March 24, 2017 07:24
Mutalyzer transcript mapping imports
# NCBI36
wget ftp://ftp.ncbi.nlm.nih.gov/genomes/MapView/Homo_sapiens/sequence/BUILD.36.3/initial_release/seq_gene.md.gz -O - \
| zcat | sort -t $'\t' -k 11,11 -k 2,2 > /tmp/hg18.seq_gene.sorted.md
mutalyzer-admin assemblies import-mapview -a hg18 /tmp/hg18.seq_gene.sorted.md 'reference'
mutalyzer-admin assemblies import-reference -a hg18 'NC_001807.4'
# GRCh37
wget ftp://ftp.ncbi.nlm.nih.gov/genomes/MapView/Homo_sapiens/sequence/ANNOTATION_RELEASE.105/initial_release/seq_gene.md.gz -O - \
| zcat | sort -t $'\t' -k 11,11 -k 2,2 > /tmp/hg19.seq_gene.sorted.md
mutalyzer-admin assemblies import-mapview -a hg19 /tmp/hg19.seq_gene.sorted.md 'GRCh37.p13-Primary Assembly'