Skip to content

Instantly share code, notes, and snippets.

View thejoltjoker's full-sized avatar

Johannes thejoltjoker

View GitHub Profile
@terrettaz
terrettaz / jpeg-keywords.py
Last active December 8, 2019 20:15
JPEG Keywords
#!/usr/bin/python
# -*- coding: iso-8859-1 -*-
__version__ = "$Revision: 0.1 $"
__author__ = "Pierrick Terrettaz"
__date__ = "2007-08-15"
import argparse, subprocess
if __name__ == '__main__':
parser = argparse.ArgumentParser(description='JPEG Keywords')
@kporangehat
kporangehat / sgtk_user_auth_interactive.py
Last active September 25, 2017 23:38
Shotgun Toolkit Authentication examples
# Import Toolkit so we can access to Toolkit specific features.
import sgtk
# Import the ShotgunAuthenticator from the tank_vendor.shotgun_authentication
# module. This class allows you to authenticate either programmatically or, in this
# case, interactively.
from tank_vendor.shotgun_authentication import ShotgunAuthenticator
# Instantiate the CoreDefaultsManager. This allows the ShotgunAuthenticator to
# retrieve the site, proxy and optional script_user credentials from shotgun.yml
Here are a few questions that will tee us up for a good conversation:
- Can you tell me about your project in a few sentences?
- What’s the timeframe? Does a certain event depend on this project launching?
- What are you looking for from us? Do you want us to design, build, and launch the whole site? Or do you have developers or other partners lined up and only need us for design?
- Have you already started on any part of the project? Do you have existing work? A new logo? Some rough designs or ideas for the site?
- How large is your team? What are the roles you envision on your end?
- How did you hear about our work? What specifically interests you about it? Any projects that you’re keen on?
- How much money have you set aside for this project?
- Are you talking to others about this project? Might we ask how many? What do you like about their work?
@softstar1990
softstar1990 / snippets.py
Created June 15, 2015 02:11
Python snippets
# -*- coding: utf-8 -*-
"""
Created on Fri Jun 12 23:18:02 2015
@author: ZhuJiaqi
"""
# loop=======================================================
days = ["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]
for i, d in enumerate(days):
print i, d
@peace098beat
peace098beat / MainApplication.py
Created April 28, 2015 12:18
[PyQt] Drag and Drop files
class MainWidget(QtGui.QMainWindow):
def __init__(self, parent=None):
super(MainWidget, self).__init__(parent)
self.setWindowTitle("FiFiFactory App")
self.resize(720,480)
self.setAcceptDrops(True)
def dragEnterEvent(self, event):
if event.mimeData().hasUrls():
event.accept()
@anthonyholmes
anthonyholmes / bootstrap-sass-mixin-cheatsheet.scss
Created October 10, 2014 08:13
Bootstrap Sass Mixin Cheatsheet
// Alerts
@include alert-variant($background, $border, $text-color);
// Background Variant
@include bg-variant($parent, $color);
// Border Radius
@include border-top-radius($radius);
@include border-right-radius($radius);
@include border-bottom-radius($radius);
@tcrowson
tcrowson / modo_SaveIncremental.py
Last active November 13, 2018 12:20
Increment the version number of the current Modo scene, respecting existing digit padding.
#python
# tc_SaveIncremental.py
# Tim Crowson, 9/29/2014
# Saves a new version of your current scene. Requires the scene to have been saved previously.
# - Searches for an existing version that follows the pattern 'sceneName_vXXX.lxo'
# - Any number of digits can be used for the version number: the script will respect the existing number padding.
# - If no version is identified (e.g. "sceneName.lxo") the script will append '_v001' to end of the scene name.
# - You can configure the padding for this First Version by setting the FIRST_VERSION_PADDING variable
@fredrikaverpil
fredrikaverpil / get_set_values.py
Last active May 20, 2024 20:31
Get and set knob values #nuke
# Get all nodes of type Read
readnodes = nuke.allNodes('Read')
for readnode in readnodes:
print readnode
# List all knobs for selected node
print( nuke.toNode('Read1') )
# List all knobs for specific node
print( nuke.selectedNode() )
@fredrikaverpil
fredrikaverpil / padding.py
Last active March 23, 2017 01:26
Add padding to number #python
# Make 13 into 0013
'{:04}'.format(13)
@tadast
tadast / countries_codes_and_coordinates.csv
Last active April 18, 2025 20:30
Countries with their (ISO 3166-1) Alpha-2 code, Alpha-3 code, UN M49, average latitude and longitude coordinates
Country Alpha-2 code Alpha-3 code Numeric code Latitude (average) Longitude (average)
Afghanistan AF AFG 4 33 65
Åland Islands AX ALA 248 60.116667 19.9
Albania AL ALB 8 41 20
Algeria DZ DZA 12 28 3
American Samoa AS ASM 16 -14.3333 -170
Andorra AD AND 20 42.5 1.6
Angola AO AGO 24 -12.5 18.5
Anguilla AI AIA 660 18.25 -63.1667
Antarctica AQ ATA 10 -90 0