This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Parallel | |
08 Fö 3 | |
09 Fö 4 | |
Fö 5 | |
10 Fö 6 | |
12 LE 1 | |
15 LA 1 AC | |
16 FÖ 7 | |
LA 1 B |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- GistID: 5038439 | |
data Term | |
= TmTrue | |
| TmFalse | |
| TmZero | |
| TmIf Term Term Term | |
| TmSucc Term | |
| TmPred Term | |
| TmIsZero Term | |
| PreviousWasNormalForm |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# encoding: utf-8 | |
# GistID: 4676361 | |
import re | |
from operator import itemgetter | |
def get_tracks_by_popularity(no_tracks, track_provider, no_matches): | |
''' | |
Retrieves the most popular tracks. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
" Save, quit, etc | |
nnoremap <silent> <leader>s :w<cr> | |
nnoremap <silent> <leader>w :wa<cr> | |
nnoremap <silent> <leader>x :wq<cr> | |
nnoremap <silent> <leader>d :q<cr> | |
nnoremap <silent> <leader>c :qa<cr> | |
" Disable Ex mode | |
map Q <Nop> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
GistID: 4515800 | |
Replacement for seemingly shitty autoclose | |
https://github.com/Raimondi/delimitMate | |
Replacement for ultrapooty Snipmate | |
https://github.com/guns/ultisnips | |
Replacement for pooty SuperTab (this is some seriously cool shit! also still maintained) | |
https://github.com/Shougo/neocomplcache |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from booking.models import User, Remark, ResourceType, Resource, Reservation | |
from django.contrib import admin | |
# Used instead of admin.ModelAdmin for translated models. | |
from hvad.admin import TranslatableAdmin | |
class ResourceTypeAdmin(TranslatableAdmin): | |
fields = ['image', 'type_name'] | |
admin.site.register(User) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
exception_message_on_failure = '' | |
try: | |
exception_message_on_failure = 'Could not access database.' | |
neurons = database.query(Neurons, state='Firing') | |
exception_message_on_failure = 'Failed doing some thing.' | |
some.thing() | |
exception_message_on_failure = 'Could not format data.' | |
output = format(neurons) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
I've included below some example JSON output from this script. First, | |
a couple of normal treenodes, then a connector with no pre- or post- | |
synaptic relationships, finally a connector with some of both: | |
[ | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# assumes: | |
# X >= Y >= Z (will work otherwise, but suboptimally) | |
turn_switch = False | |
def switch(): | |
if turn_switch: | |
turn_switch = False | |
else: | |
turn_switch = True |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$canEdit = $db->getResult( | |
'SELECT "textlabel"."id" AS "tid" | |
FROM "textlabel" INNER JOIN "project" | |
ON "project"."id" = "textlabel"."project_id" INNER JOIN "project_user" | |
ON "project"."id" = "project_user"."project_id" | |
WHERE "textlabel"."id" = '.$tid.' AND | |
"project_user"."user_id" = '.$uid.' AND | |
"project_user"."project_id" = '.$pid ); |