Skip to content

Instantly share code, notes, and snippets.

@jstnlvns
jstnlvns / SSLPoke.java
Last active August 29, 2015 14:24 — forked from 4ndrej/SSLPoke.java
import javax.net.ssl.SSLSocket;
import javax.net.ssl.SSLSocketFactory;
import java.io.*;
/** Establish a SSL connection to a host and port, writes a byte and
* prints the response. See
* http://confluence.atlassian.com/display/JIRA/Connecting+to+SSL+services
*/
public class SSLPoke {
public static void main(String[] args) {
@jstnlvns
jstnlvns / sort_csv.py
Last active August 29, 2015 14:26 — forked from JimHaughwout/sort_csv.py
Sort CSV file by multiple columns, writing output to sorted CSV file.
#! /usr/bin/env python
"""
Sort CSV file by multiple columns, writing output to sorted CSV file.
Recommended for files saved in Windows CSV format.
Useful for situations where data file is too large for Excel.
: param source_file.csv : source csv file. Must end in .csv
: param sort column 1 : first sort in Excel-like column number (i.e., 1 ... N)
Use negative number to indicate descending sort,
Positive number to indicate ascending sort_step