Skip to content
Snippets Groups Projects
Commit 8eda2a2e authored by Riccardo Boero's avatar Riccardo Boero :innocent:
Browse files

Merge branch 'new-branch-with-fixed-history' into 'main'

New branch with fixed history

See merge request !1
parents b378b3e4 56265cdf
No related branches found
No related tags found
1 merge request!1New branch with fixed history
echo "*** Dump database:" echo "*** Dump database:"
mkdir -p ./dump mkdir -p ./dump
mariadb-dump -h "plazablanca.nilu.no" -u "root" -pimpadminPSWD! --databases FACT_mine > ./dump/db_mine.sql mariadb-dump -h "" -u "root" -p --databases FACT_mine > ./dump/db_mine.sql
echo "*** Drop database:" echo "*** Drop database:"
mariadb -h "plazablanca.nilu.no" -u "root" -pimpadminPSWD! < inputs/sql/drop_db.sql mariadb -h "" -u "root" -p < inputs/sql/drop_db.sql
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
mkdir -p ./temp mkdir -p ./temp
wget -O ./temp/temp.zip -N "https://ftp.maps.canada.ca/pub/nrcan_rncan/publications/STPublications_PublicationsST/223/223767/of_5529.zip" wget -O ./temp/temp.zip -N "https://ftp.maps.canada.ca/pub/nrcan_rncan/publications/STPublications_PublicationsST/223/223767/of_5529.zip"
unzip -d ./temp/ ./temp/temp.zip unzip -d ./temp/ ./temp/temp.zip
ogr2ogr -f MySQL MySQL:FACT_mine,host=plazablanca.nilu.no,user=root,password=impadminPSWD! ./temp/data/ArcMap9_ArcReader9/AllThemesMerged/gen.shp -nln geology -update -overwrite -lco engine=Aria -t_srs EPSG:4326 ogr2ogr -f MySQL MySQL:FACT_mine,host=,user=root,password= ./temp/data/ArcMap9_ArcReader9/AllThemesMerged/gen.shp -nln geology -update -overwrite -lco engine=Aria -t_srs EPSG:4326
chmod -R u+w temp/ chmod -R u+w temp/
sudo rm -r ./temp sudo rm -r ./temp
...@@ -15,7 +15,7 @@ do ...@@ -15,7 +15,7 @@ do
mkdir -p ./temp mkdir -p ./temp
wget -O ./temp/temp.zip -N "https://mrdata.usgs.gov/${m}/${m}-csv.zip" wget -O ./temp/temp.zip -N "https://mrdata.usgs.gov/${m}/${m}-csv.zip"
unzip -d ./temp/ ./temp/temp.zip unzip -d ./temp/ ./temp/temp.zip
ogr2ogr -f MySQL MySQL:FACT_mine,host=plazablanca.nilu.no,user=root,password=impadminPSWD! ./temp/${m}/${m}.shp -nln ${m} -update -overwrite -lco engine=Aria -t_srs EPSG:4326 ogr2ogr -f MySQL MySQL:FACT_mine,host=,user=root,password= ./temp/${m}/${m}.shp -nln ${m} -update -overwrite -lco engine=Aria -t_srs EPSG:4326
chmod -R u+w temp/ chmod -R u+w temp/
rm -r ./temp rm -r ./temp
done done
...@@ -24,6 +24,6 @@ done ...@@ -24,6 +24,6 @@ done
mkdir -p ./temp mkdir -p ./temp
wget -O ./temp/temp.zip -N "https://www.sciencebase.gov/catalog/file/get/594d3c8ee4b062508e39b332?name=PP1802_CritMin_Shapefiles.zip" wget -O ./temp/temp.zip -N "https://www.sciencebase.gov/catalog/file/get/594d3c8ee4b062508e39b332?name=PP1802_CritMin_Shapefiles.zip"
unzip -d ./temp/ ./temp/temp.zip unzip -d ./temp/ ./temp/temp.zip
ogr2ogr -f MySQL MySQL:FACT_mine,host=plazablanca.nilu.no,user=root,password=impadminPSWD! ./temp/PP1802_CritMin_pts.shp -nln global_selected -update -overwrite -lco engine=Aria -t_srs EPSG:4326 ogr2ogr -f MySQL MySQL:FACT_mine,host=,user=root,password= ./temp/PP1802_CritMin_pts.shp -nln global_selected -update -overwrite -lco engine=Aria -t_srs EPSG:4326
chmod -R u+w temp/ chmod -R u+w temp/
rm -r ./temp rm -r ./temp
echo "*** Create database:" echo "*** Create database:"
mariadb -h "plazablanca.nilu.no" -u "root" -pimpadminPSWD! < inputs/sql/create_db.sql mariadb -h "" -u "root" -p < inputs/sql/create_db.sql
#echo "*** Create tables:" #echo "*** Create tables:"
#mariadb -h "plazablanca.nilu.no" -u "root" -pimpadminPSWD! < inputs/sql/create_tables.sql #mariadb -h "" -u "root" -p < inputs/sql/create_tables.sql
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment