Skip to content

Instantly share code, notes, and snippets.

View nestorcolt's full-sized avatar
💭
working or something

Nestor Colt nestorcolt

💭
working or something
  • Barcelona, Spain
View GitHub Profile
@cedricduriau
cedricduriau / progressbar.py
Created October 25, 2020 13:57
CLI/GUI Progress Bar
# stdlib modules
import sys
import time
# third party modules
from PySide2 import QtCore, QtWidgets
class AbstractProgressBar(QtCore.QObject):
# signals
@nestorcolt
nestorcolt / cloudSettings
Last active October 31, 2018 11:36
Visual Studio Code Settings Sync Gist
{"lastUpload":"2018-10-31T11:36:45.885Z","extensionVersion":"v3.2.0"}
@hdlx
hdlx / getClosestVertex.py
Last active September 21, 2023 08:19
Maya get closest vertex
import maya.api.OpenMaya as om
import maya.cmds as cmds
#returns the closest vertex given a mesh and a position [x,y,z] in world space.
#Uses om.MfnMesh.getClosestPoint() returned face ID and iterates through face's vertices.
def getClosestVertex(mayaMesh,pos=[0,0,0]):
mVector = om.MVector(pos)#using MVector type to represent position
selectionList = om.MSelectionList()
selectionList.add(mayaMesh)
dPath= selectionList.getDagPath(0)
@mrkrndvs
mrkrndvs / export-named-sheet-as-csv.gs
Last active May 4, 2024 21:53 — forked from mderazon/export-to-csv.gs
Google apps script to export an individual sheet as csv file
/*
* script to export data of the named sheet as an individual csv files
* sheet downloaded to Google Drive and then downloaded as a CSV file
* file named according to the name of the sheet
* original author: Michael Derazon (https://gist.github.com/mderazon/9655893)
*/
function onOpen() {
var ss = SpreadsheetApp.getActiveSpreadsheet();
var csvMenuEntries = [{name: "Download Primary Time File", functionName: "saveAsCSV"}];
@jojobyte
jojobyte / ContextCmder-Disable.reg
Last active October 5, 2023 13:13
Cmder Context (Right-Click) Menu for Windows 7, 8, 10 & 11
Windows Registry Editor Version 5.00
[-HKEY_CLASSES_ROOT\Directory\Background\shell\Cmder]
[-HKEY_CLASSES_ROOT\Directory\shell\Cmder]
@theodox
theodox / mayaPyManager.py
Last active January 17, 2023 09:50
Exposes the MayaPyManager class, which is used to run instances of MayaPy with explict control over paths and environment variables. A Manager can run scripts, modules, or command strings in a separate MayaPy environment; results and errors are captured and returned.
'''
Exposes the MayaPyManager class, which is used to run instances of MayaPy with explict control over paths and environment variables. A Manager can run scripts, modules, or command strings in a separate MayaPy environment; results and errors are captured and returned.
Typical uses might be:
- running unit tests
- running a copy of Maya.standalone as a headless RPC server with StandaloneRPC https://github.com/theodox/standaloneRPC
- spawning multipe copies of maya to batch process files in parallel on a multi-core machine
- do any of the above on multiple maya versions concurrently