Skip to content

Instantly share code, notes, and snippets.

View AnnamalaiNagappan's full-sized avatar

Annamalai Nagappan AnnamalaiNagappan

  • Gramener
  • Hyderabad, India
View GitHub Profile
@AnnamalaiNagappan
AnnamalaiNagappan / migrate_to_github.py
Created December 15, 2016 13:00 — forked from andreifecioru/migrate_to_github.py
Migrating git repos to GitHub
#!/usr/bin/env python
import sys
import sh
import json
import requests
from optparse import OptionParser
from contextlib import contextmanager
@AnnamalaiNagappan
AnnamalaiNagappan / api_call.py
Last active December 15, 2016 12:46
Using python to get udacity courses via their API and store it in csv file
'''
1. Get latest updates on udacity courses via their API
2. Using python and pandas will get all the details about courses in a csv file
'''
import json
import urllib
import pandas as pd
response = urllib.urlopen('https://udacity.com/public-api/v0/courses')
@AnnamalaiNagappan
AnnamalaiNagappan / conversion.py
Created September 26, 2016 12:33
python script to convert all python .py files inside the current directory and all its subdirectories into .pyc and remove all .py files
import compileall
import os
# Get current working directory
curr_dir = os.getcwd()
# Compiles all python files to pyc
compileall.compile_dir(curr_dir, force=True)
# Recursively iterates to find .py files and remove them
@AnnamalaiNagappan
AnnamalaiNagappan / gulp.js
Last active August 29, 2015 14:18
Gulp Automation
/*
This command installs gulp (globally)
npm install --global gulp
The below listed commands should be done in your project/development folder
npm install --save-dev gulp
npm install --save-dev gulp-minify-css
npm install --save-dev gulp-uglify