Skip to content

Instantly share code, notes, and snippets.

View nicoddemus's full-sized avatar

Bruno Oliveira nicoddemus

View GitHub Profile
@jjhelmus
jjhelmus / update_token.py
Created August 14, 2017 23:38
Python script to update the Anaconda upload token in conda-forge feedstocks
from __future__ import print_function
import os
import requests
import ruamel.yaml
with open(os.path.expanduser('~/.conda-smithy/circle.token'), 'r') as fh:
circle_token = fh.read().strip()
@canassa
canassa / fix_pytest.py
Last active December 8, 2015 08:59
Converts self.assertEquals to assert
"""
Replaces unittest style asserts (e.g.: self.assertEqual) with py.test style asserts
Usage:
from lib2to3.refactor import RefactoringTool
refactoring_tool = RefactoringTool(['fix_pytest'])
refactoring_tool.refactor(['input.py'], write=True)
"""