From bbc26e321ee003f6749004182d143b2c031d4e7d Mon Sep 17 00:00:00 2001
From: Mart Lubbers
Date: Tue, 9 Dec 2014 13:18:00 +0100
Subject: [PATCH] update put.bash
---
hashes.txt | 6 +++---
index.html | 2 +-
put.bash | 7 +++----
robots.txt | 2 +-
4 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/hashes.txt b/hashes.txt
index 4b2b845..40075a2 100644
--- a/hashes.txt
+++ b/hashes.txt
@@ -1,13 +1,13 @@
3d85a9b435eb833de088e45c3f56e49c ./dvorak.html
9e5b7702d73bfb7febb24bf58f0e8d60 ./hashes.txt
-198a371dd238282e3fa78732be9fbfdb ./index.html
+b7466a31f0ee30450485852855af887c ./index.html
72ac29b74f3e09c551aa10a2a8d2581d ./lejos-ubuntu.html
0ba6cb2c3a9d7d8ba27406d215aa501e ./mart@martlubbers.net.asc
75068866762dc200d6e185bfe9b3a2bf ./o.html
ce31052406b3874b287e98c8a9477516 ./p.jpg
-e0242c7228f6ef8da9747516c597f52c ./put.bash
+e8a032f7db299973004f4baad35967a9 ./put.bash
43eb61826bc538817b4c78c7f8d57019 ./README.md
-4be5b32df3dedb74eeb758b233864fe6 ./robots.txt
+acaac946ac8dc79dc3896e74edbdd303 ./robots.txt
d69f225d06c3d7a417fb5e8159efc2d1 ./test.php
146f1bb6bed2adfd4d13f9644390db71 ./archive/nsa-dropbox.html
2ed34aa229468632cce58151c33d1ebc ./archive/wlan-debian.html
diff --git a/index.html b/index.html
index 71422fb..9a90a0a 100644
--- a/index.html
+++ b/index.html
@@ -29,7 +29,7 @@
Work
Student Assistant at Max Planck Institute for Psycholinguistics
- in the Language and Cognition department.
+ in the Language and Cognition department.
Research Interests
diff --git a/put.bash b/put.bash
index 665e574..80770f6 100644
--- a/put.bash
+++ b/put.bash
@@ -1,8 +1,7 @@
#!/bin/bash
set -e
files=$(find . -type f -not -iwholename "*.git*")
-user=$(gpg -q --use-agent -d ~/pw/general.asc | grep ftpmartlubbers.net -A3 | grep -Po "(?<=user: ).*")
-pass=$(gpg -q --use-agent -d ~/pw/general.asc | grep ftpmartlubbers.net -A3 | grep -Po "(?<=pass: ).*")
+user=$(gpg -q --use-agent -d ~/pw/general.asc | grep ftpmartlubbers.net -A3 | head -3 | tail -2 | sed 's/\s\+\(user\|pass\):\s\+//g' | head -c -1 | tr '\n' ':')
for f in $files
do
@@ -13,7 +12,7 @@ do
echo "$f is not changed"
else
echo "$f is changed"
- curl -u "$user:$pass" -T $f ftp://martlubbers.net/public_html/$f
+ curl -u "$user" -T $f ftp://martlubbers.net/public_html/$f
fi
done
-md5sum ./*{,/*} > ./hashes.txt
+md5sum ./*{,/*} > ./hashes.txt || true
diff --git a/robots.txt b/robots.txt
index 634ad20..1a3761a 100644
--- a/robots.txt
+++ b/robots.txt
@@ -1,3 +1,3 @@
# go away
User-agent: *
-Disallow: /
\ No newline at end of file
+Disallow: /
--
2.20.1