Skip to content

Instantly share code, notes, and snippets.

@zx1986
zx1986 / get_sst.py
Created December 22, 2011 02:16
Get files through FTP from discover-earth
#!/usr/bin/python
# -*-coding:utf-8-*-
from ftplib import FTP
import logging
import sys
import os
ftp_host="ftp.discover-earth.org"
ftp_dir="sst/daily/tmi_amsre/"
@zx1986
zx1986 / get_file_noaa.sh
Created August 22, 2011 03:22
get GFS files from NOAA
#!/bin/bash
# issue 1427
# get GFS files from NOAA (http://nomads.ncep.noaa.gov/cgi-bin/filter_gfs_hd.pl) and save to $SAVE_DIR directory
# @author <zx1986> 02-2349-1219
### Global Configuration ###
# absolute path of the directory which saves all downloading files
SAVE_DIR=/users3/mavis/noaadata
function my_fun(var)
{
this.var = var;
alert(this.var);
}
$('#id').click( my_fun('hello') );
message = 'hello';
$('#id').click( my_fun(message) );