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
| $media-queries: true; | |
| @mixin bp($point) { | |
| @if ($media-queries) { | |
| $bp-large-screen: 1824px; | |
| $bp-bigscreen: 1824px; | |
| $bp-ipad-max: 1024px; | |
| $bp-ipad-min: 768px; | |
| $bp-iphone5-max: 568px; | |
| $bp-iphone-max: 480px; |
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
| #!/bin/bash | |
| # | |
| # git-mv-with-history -- move/rename file or folder, with history. | |
| # | |
| # Moving a file in git doesn't track history, so the purpose of this | |
| # utility is best explained from the kernel wiki: | |
| # | |
| # Git has a rename command git mv, but that is just for convenience. | |
| # The effect is indistinguishable from removing the file and adding another | |
| # with different name and the same content. |
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
| Sep 12 15:07:27 hostname kernel: [ 8622.614779] vgaarb: this pci device is not a vga device | |
| Sep 12 15:07:57 hostname wpa_supplicant[1554]: wlan0: CTRL-EVENT-SCAN-STARTED | |
| Sep 12 15:09:00 hostname wpa_supplicant[1554]: wlan0: CTRL-EVENT-SCAN-STARTED | |
| Sep 12 15:09:01 hostname CRON[16411]: (root) CMD ( [ -x /usr/lib/php5/maxlifetime ] && [ -x /usr/lib/php5/sessionclean ] && [ -d /var/lib/php5 ] && /usr/lib/php5/sessionclean /var/lib/php5 $(/usr/lib/php5/maxlifetime)) | |
| Sep 12 15:10:23 hostname wpa_supplicant[1554]: wlan0: CTRL-EVENT-SCAN-STARTED | |
| Sep 12 15:16:06 hostname wpa_supplicant[1554]: message repeated 4 times: [ wlan0: CTRL-EVENT-SCAN-STARTED ] | |
| Sep 12 15:17:01 hostname CRON[16509]: (root) CMD ( cd / && run-parts --report /etc/cron.hourly) | |
| Sep 12 15:17:03 hostname wpa_supplicant[1554]: wlan0: CTRL-EVENT-SCAN-STARTED | |
| Sep 12 15:19:28 hostname kernel: [ 9344.462540] vgaarb: this pci device is not a vga device | |
| Sep 12 15:18:06 hostname wpa_supplicant[1554]: wlan0: CTRL-EVENT-SCAN-STARTED |
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
| # // https://github.com/asyncee/django-easy-select2/tree/master/sampleproject | |
| # sampleproject/demoapp/admin.py | |
| from django.contrib import admin | |
| from django.db import models | |
| from easy_select2 import Select2 | |
| from easy_select2.widgets import SELECT2_WIDGET_JS | |
| from .models import Note, Category |
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
| // sample property callback for select2 constructor argument | |
| function formatState (state) { | |
| var baseUrl = "http://lorempixel.com/4/4/"; | |
| var $state = $( | |
| '<span><img src="' + baseUrl + '" class="img-flag" /> ' + (state.title || state.text)+ '</span>' | |
| ); | |
| return $state; | |
| }; | |
| function formatTodo (repo) { | |
| if (repo.loading) { |
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
| /** | |
| * issue #52(hot fix) | |
| * the below code is to replace the DomNodeInserted JQuery block code(django-easy-selectv1.5.3/easy-select2.js) with below implementation as it is. | |
| * this implementation is confirmed for issue-52 | |
| * (currently in performance testing to make a production release for this implementation) | |
| */ | |
| // Select the node that will be observed for mutations | |
| var targetNode = document.documentElement || document.body; |
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
| def pretty_request(request): | |
| headers = '' | |
| for header, value in request.META.items(): | |
| if not header.startswith('HTTP'): | |
| continue | |
| header = '-'.join([h.capitalize() for h in header[5:].lower().split('_')]) | |
| headers += '{}: {}\n'.format(header, value) | |
| return ( | |
| '{method} HTTP/1.1\n' |
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
| function getHex(input) { | |
| var ss = SpreadsheetApp.getActiveSpreadsheet(); | |
| var cell = ss.getRange(input); | |
| var result = cell.getBackground(); | |
| return result | |
| } |
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
| # curl -sL bit.ly/p7virtualenv | bash | |
| curl -O https://pypi.python.org/packages/source/v/virtualenv/virtualenv-12.0.5.tar.gz | |
| tar xzf virtualenv-12.0.5.tar.gz && rm virtualenv-12.0.5.tar.gz | |
| mv virtualenv-12.0.5 ~/.virtualenv | |
| echo >> ~/.bashrc | |
| echo "alias virtualenv='python $HOME/.virtualenv/virtualenv.py'" >> ~/.bashrc | |
| echo 'Now run: source ~/.bashrc' |
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
| license: mit |