$ sudo apt-get install unattended-upgrades
$ sudo nano /etc/apt/apt.conf.d/10periodic
import os | |
from django.core.exceptions import ValidationError | |
from django.core.files.images import get_image_dimensions | |
from django.utils.deconstruct import deconstructible | |
from wagtail.images.models import Image # To get the image object from wagtail collections | |
@deconstructible | |
class ImageValidator: | |
"""ImageField dimensions validator.""" |
# Author: Zameer Ansari | |
# You should look at the following URL's in order to grasp a solid understanding | |
# of Nginx configuration files in order to fully unleash the power of Nginx. | |
# http://wiki.nginx.org/Pitfalls | |
# http://wiki.nginx.org/QuickStart | |
# http://wiki.nginx.org/Configuration | |
# | |
# Generally, you will want to move this file somewhere, and start with a clean | |
# file but keep this around for reference. Or just disable in sites-enabled. | |
# |
Functions defined in dota\scripts\vscripts\framework\entities | |
--usage EntityFramework.CreateEntity(...) | |
CreateEntity [function, function: 0x169ab288] | |
GetScriptClassForDesignerName [function, function: 0x169a4d08] | |
GetNativeClassForScriptClass [function, function: 0x169a5258] | |
scriptClassTable [table, table: 0x169ab2c0] | |
InstallClasses [function, function: 0x169a77a8] | |
GetEntityHandle [function, function: 0x169ab310] | |
RegisterScriptClass [function, function: 0x169a7790] |
-- Adapted from these sources: | |
-- http://peterdowns.com/posts/open-iterm-finder-service.html | |
-- https://gist.github.com/cowboy/905546 | |
-- | |
-- Modified to work with files as well, cd-ing to their container folder | |
on run {input, parameters} | |
tell application "Finder" | |
set my_file to first item of input | |
set filetype to (kind of (info for my_file)) | |
-- Treats OS X applications as files. To treat them as folders, integrate this SO answer: |