Skip to content

Instantly share code, notes, and snippets.

View vanjacosic's full-sized avatar
💭
Available for freelance work 😊

Vanja Cosic vanjacosic

💭
Available for freelance work 😊
View GitHub Profile
@vanjacosic
vanjacosic / keybase.md
Created September 11, 2018 17:44
keybase.md

Keybase proof

I hereby claim:

  • I am vanjacosic on github.
  • I am vanjacosic (https://keybase.io/vanjacosic) on keybase.
  • I have a public key ASDiTfcuxbrNTtbJqmnp4p5K-nSfQA5xgJL1apTqyp2VrQo

To claim this, I am signing this object:

@vanjacosic
vanjacosic / gdpr_template.md
Created August 3, 2018 12:36
GDPR email template

Email template for requesting data deletion

To:

Their Data Protection Officer, usually dpo@companyname.com

Subject:

Request for erasure (GDPR)

@vanjacosic
vanjacosic / README.md
Created November 7, 2015 11:15
Assets in Django with gulp pipeline

Assets in Django with gulp as a pipeline

by @piquadrat and @vanjacosic from Opbeat.

This is the approach we use on Opbeat.com. In gulp it uses the gulp-asset-manifest module. In Django, it uses custom template tags to load the manifest.

We use it for JS and CSS, in this example it's some JS library files.

gulpfile.js

@vanjacosic
vanjacosic / pre-commit
Last active August 29, 2015 14:16
git pre-commit hook that prevents user from comitting to master branch
#!/usr/bin/python
# Pre-commit hook to prevent commits in the master branch ('prod' in our case)
# Create a filed named 'pre-commit' in your local repository in the '.git/hooks' folder
# and make sure it is executable by using `chmod +x .git/hooks/pre-commit`
from subprocess import check_output
FORBIDDEN_BRANCH = 'prod'
CURRENT_BRANCH = str(
@vanjacosic
vanjacosic / sublime-snippets
Created August 17, 2012 13:14
Købstaden snippets
[{ "keys": ["super+ctrl+l"], "command": "insert_snippet", "args": {"name": "Packages/User/jslog.sublime-snippet"} },
{ "keys": ["super+ctrl+e"], "command": "insert_snippet", "args": {"name": "Packages/User/mootools-newElement.sublime-snippet"} },
{ "keys": ["super+ctrl+t"], "command": "insert_snippet", "args": {"name": "Packages/User/localization.sublime-snippet"} }
]
jslog.sublime-snippet:
<snippet>
<content><![CDATA[console.log(${1:$SELECTION});]]></content>
<tabTrigger>l!</tabTrigger>