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
| -- CREATE read-only user when the user was created via the Google Cloud API (ie terraform) | |
| -- GOOGLE CLOUD by default give fairly broad permissions | |
| -- Prior reading https://stackoverflow.com/questions/13497352/error-permission-denied-for-relation-tablename-on-postgres-while-trying-a-selec | |
| -- https://www.digitalocean.com/docs/databases/postgresql/how-to/modify-user-privileges/ | |
| REVOKE ALL ON DATABASE db FROM "dev-readonly"; | |
| -- This next line is important | |
| REVOKE cloudsqlsuperuser FROM "dev-readonly"; | |
| GRANT USAGE ON SCHEMA public TO "dev-readonly"; | |
| ALTER DEFAULT PRIVILEGES IN SCHEMA public GRANT SELECT ON TABLES TO "dev-readonly"; |
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
| ''' | |
| Template class for docking a Qt widget to maya 2017+. | |
| Author: Lior ben horin | |
| 12-1-2017 | |
| ''' | |
| import weakref | |
| import maya.cmds as cmds | |
| import maya.OpenMayaUI as omui |
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
| CREATE SEQUENCE country_seq; | |
| CREATE TABLE IF NOT EXISTS country ( | |
| id int NOT NULL DEFAULT NEXTVAL ('country_seq'), | |
| iso char(2) NOT NULL, | |
| name varchar(80) NOT NULL, | |
| nicename varchar(80) NOT NULL, | |
| iso3 char(3) DEFAULT NULL, | |
| numcode smallint DEFAULT NULL, | |
| phonecode int NOT NULL, |
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
| import maya.cmds as mc | |
| def _null(*args): | |
| pass | |
| class _shelf(): | |
| '''A simple class to build shelves in maya. Since the build method is empty, | |
| it should be extended by the derived class to build the necessary shelf elements. |
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
| """ | |
| This is what you need to do in order to get a qt window to dock next to maya channel box, | |
| In all maya versions, including 2017 with PySide2 | |
| """ | |
| __author__ = "liorbenhorin@gmail.com" | |
| import sys | |
| import os | |
| import logging | |
| import xml.etree.ElementTree as xml |