Skip to content

Instantly share code, notes, and snippets.

View vishwasjois's full-sized avatar

Vishwas vishwasjois

View GitHub Profile
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-Type"
content="text/html; charset=utf-8" />
<script src="jquery-1.7.2.min.js" ></script>
<script src="handlebars-1.0.0.beta.6.js" ></script>
<script src="underscore-min.js" ></script>
<script src="backbone-min.js" ></script>
@vishwasjois
vishwasjois / Object Flatten
Created May 10, 2016 02:00 — forked from penguinboy/Object Flatten
Flatten javascript objects into a single-depth object
var flattenObject = function(ob) {
var toReturn = {};
for (var i in ob) {
if (!ob.hasOwnProperty(i)) continue;
if ((typeof ob[i]) == 'object') {
var flatObject = flattenObject(ob[i]);
for (var x in flatObject) {
if (!flatObject.hasOwnProperty(x)) continue;
//
// Regular Expression for URL validation
//
// Author: Diego Perini
// Updated: 2010/12/05
// License: MIT
//
// Copyright (c) 2010-2013 Diego Perini (http://www.iport.it)
//
// Permission is hereby granted, free of charge, to any person
@vishwasjois
vishwasjois / download-latest-jenkins-artifact.py
Created March 6, 2018 07:10 — forked from jmcgeheeiv/download-latest-jenkins-artifact.py
Download the latest successful build artifacts from Jenkins using Python 3
#!/usr/bin/env python3
# Download the latest successful build artifacts from Jenkins using Python 3
# John McGehee 1/25/2016
#
# Based on the Python 2 version by supertom: https://gist.github.com/supertom/2759847
import argparse
import codecs
import io
import json
@vishwasjois
vishwasjois / fetch_debs_from_jenkins.py
Created March 6, 2018 07:11 — forked from supertom/fetch_debs_from_jenkins.py
download artifacts from jenkins with python
#!/usr/bin/env python
import cStringIO
import json
import pycurl
import os
import sys
##########
# configuration