#!/bin/csh
set echo
# script to download the aviso observations
# ftp://my.cmems-du.eu/Core/SEALEVEL_GLO_PHY_L3_REP_OBSERVATIONS_008_045/dataset-duacs-rep-global-en-phy-l3
# june 11, now:
# ftp://my.cmems-du.eu/Core/SEALEVEL_GLO_PHY_L3_REP_OBSERVATIONS_008_062/dataset-duacs-rep-global-en-phy-l3
#
setenv pass "hifhuw-qerxur-poBpo3"
setenv WP "ftp://my.cmems-du.eu/Core/SEALEVEL_GLO_PHY_L3_REP_OBSERVATIONS_008_062/"
foreach y ( 2020)
foreach mon ( 01 02 03 04 05 06 07 )
## 201504-201910
#mkdir -p alg
cd alg/ 
wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-alg-phy-l3/${y}/${mon}/*"
cd ../
#end
## 201303-201503
# mkdir -p al
# cd al/
# wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-al-phy-l3/${y}/${mon}/*"
# cd ../
#end

## 201102-201910
# mkdir -p c2
 cd c2/
 wget --ftp-user ${user} --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-c2-phy-l3/${y}/${mon}/*"
 cd ../
#end

## 1993-1995
#mkdir -p e1
#cd e1/
#wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-e1-phy-l3/2011/*"
#cd ../

## 199505-200207
#mkdir -p e2
#cd e2/
#wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-e2-phy-l3/${y}/${mon}/*"
#cd ../
#end

## 200207-201010
#mkdir -p en
#cd en/
#wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-en-phy-l3/${y}/${mon}/*"
#cd ../
#end

## 201010-201204
# mkdir -p enn
# cd enn/
# wget --ftp-user abozec --ftp-password ${pass}  "${WP}/dataset-duacs-rep-global-enn-phy-l3/${y}/${mon}/*"
# cd ../
# end

## 200001-200809
#mkdir -p g2
#cd g2/
#wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-g2-phy-l3/${y}/${mon}/*"
#cd ../
#end

## 201404-201603
#mkdir -p h2
#cd h2/
#wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-h2-phy-l3/${y}/${mon}/*"
#cd ../
#end

## 201604-201910
#mkdir -p h2g
cd h2g/
wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-h2g-phy-l3/${y}/${mon}/*"
cd ../
#end

## 200204-200810
#mkdir -p j1
#cd j1/
#wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-j1-phy-l3/${y}/${mon}/*"
#cd ../
#end

## 201205-201306
#mkdir -p j1g
#cd j1g/
#wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-j1g-phy-l3/${y}/${mon}/*"
#cd ../
#end 

## 2009i02-201203
# mkdir -p j1n
# cd j1n/
# wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-j1n-phy-l3/${y}/${mon}/*"
# cd ../
#end

## 200810-201605
#mkdir -p j2
#cd j2/
#wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-j2-phy-l3/${y}/${mon}/*"
#cd ../
#end

## 201707-201709
# mkdir -p j2g
# cd j2g/
# wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-j2g-phy-l3/${y}/${mon}/*"
# cd ../
#end

## 201610-201704
# mkdir -p j2n
# cd j2n/
# wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-j2n-phy-l3/${y}/${mon}/*"
# cd ../
#end

## 201605-201910
# mkdir -p j3
 cd j3/
 wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-j3-phy-l3/${y}/${mon}/*"
 cd ../
#end

## 201606-201910
# mkdir -p s3a
 cd s3a/
 wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-s3a-phy-l3/${y}/${mon}/*"
 cd ../
#end

## 201811-201910
# mkdir -p s3b
 cd s3b/
 wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-s3b-phy-l3/${y}/${mon}/*"
 cd ../
end

## 1993-2002
# mkdir -p tp
# cd tp/
# wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-tp-phy-l3/${y}/${mon}/*"
# cd ../
#end

## 200209-200510
# mkdir -p tpn
# cd tpn/
# wget --ftp-user abozec --ftp-password ${pass} "${WP}/dataset-duacs-rep-global-tpn-phy-l3/${y}/${mon}/*"
# cd ../
#end


end
