Skip to content

Instantly share code, notes, and snippets.

View dan-gamble's full-sized avatar

Dan Gamble dan-gamble

View GitHub Profile
{
"always-semicolon": true,
"block-indent": 4,
"color-case": "lower",
"color-shorthand": true,
"element-case": "upper",
"exclude": ["node_modules/**"],
"leading-zero": true,
"quotes": "single",
"remove-empty-rulesets": true,
{
"caret_extra_width": 1,
"caret_style": "phase",
"close_windows_when_empty": false,
"color_scheme": "Packages/User/Peacock (SL).tmTheme",
"copy_with_empty_selection": false,
"drag_text": false,
"draw_minimap_border": true,
"enable_tab_scrolling": false,
"ensure_newline_at_eof_on_save": true,
var gulp = require('gulp');
var browserSync = require('browser-sync')
var compass = require('gulp-compass');
var concat = require('gulp-concat');
var changed = require('gulp-changed');
var jshint = require('gulp-jshint');
var imagemin = require('gulp-imagemin');
var sass = require('gulp-sass');
var sourcemaps = require('gulp-sourcemaps');
var stripDebug = require('gulp-strip-debug');
from django.core.management.base import BaseCommand, CommandError
from django.utils.text import slugify
from apps.clubs.models import Club
from apps.leagues.models import League
from apps.nations.models import Nation
import requests
from django.conf import settings
from django.core.exceptions import ObjectDoesNotExist
from django.db.models.loading import get_model
from django.utils.text import slugify
from apps.leagues.models import League
from apps.nations.models import Nation
from datetime import datetime
import os
def get_context_data(self, **kwargs):
context = super(PlayerListView, self).get_context_data()
if self.request.GET:
context['form'] = PlayerFilterForm(self.request.GET)
else:
context['form'] = PlayerFilterForm
return context
<div class="field-wrapper">
<label>Overall Rating</label>
<div class="controls controls--form">{{ form.min_rating }} - {{ form.max_rating }}</div>
<div class="selected-values">
<span class="js-value-1">{{ form.min_rating.value }}</span>
to
<span class="js-value-2">{{ form.max_rating.value }}</span>
</div>
</div>
<div class="field-wrapper">
$('.field-wrapper').each(function() {
var _this = this;
$('.controls select').each(function() {
$(this).on('change', function() {
console.log($('.selected-values span:first-child', _this));
$('.selected-values span:first-child', _this).text($(this, _this).val());
});
});
[
// Anaconda
{ "keys": ["super+b"], "command": "anaconda_goto" },
// Code manipulation
{ "keys": ["super+shift+r"], "command": "reindent" },
{ "keys": ["super+shift+up"], "command": "swap_line_up" },
{ "keys": ["super+shift+down"], "command": "swap_line_down" },
{ "keys": ["super+shift+delete"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Delete Line.sublime-macro"} },
{ "keys": ["super+shift+c"], "command": "duplicate_line" },
[
// Anaconda
{ "keys": ["super+b"], "command": "anaconda_goto" },
// Code manipulation
{ "keys": ["super+shift+r"], "command": "reindent" },
{ "keys": ["super+shift+up"], "command": "swap_line_up" },
{ "keys": ["super+shift+down"], "command": "swap_line_down" },
{ "keys": ["super+shift+delete"], "command": "run_macro_file", "args": {"file": "res://Packages/Default/Delete Line.sublime-macro"} },
{ "keys": ["super+shift+c"], "command": "duplicate_line" },