fix asset ref; fix build/publish scripts
This commit is contained in:
@@ -1,14 +1,16 @@
|
||||
#!/bin/bash
|
||||
|
||||
# args: s3cmd-config
|
||||
# args: s3cmd-config asset-path
|
||||
|
||||
set -e
|
||||
|
||||
cd "./asset/$2"
|
||||
|
||||
s3cmd sync \
|
||||
--config "$1" \
|
||||
--acl-public \
|
||||
--no-preserve \
|
||||
--add-header 'cache-control:max-age=86400' \
|
||||
--verbose \
|
||||
"./asset/$2" \
|
||||
"s3://dpb587-assets-us-west-2/asset/$2"
|
||||
. \
|
||||
"s3://assets.dpb587.me/asset/$2/"
|
||||
|
||||
@@ -4,6 +4,22 @@
|
||||
|
||||
set -e
|
||||
|
||||
cd "$ARTIFACT_PATH"
|
||||
|
||||
cd static/
|
||||
|
||||
s3cmd sync \
|
||||
--config "$1" \
|
||||
--acl-public \
|
||||
--no-delete-removed \
|
||||
--no-preserve \
|
||||
--add-header 'cache-control:max-age=604800' \
|
||||
--verbose \
|
||||
. \
|
||||
s3://dpb587-us-west-2/static/
|
||||
|
||||
cd ../
|
||||
|
||||
s3cmd sync \
|
||||
--config "$1" \
|
||||
--acl-public \
|
||||
@@ -11,7 +27,8 @@ s3cmd sync \
|
||||
--no-preserve \
|
||||
--exclude 'private/*' \
|
||||
--exclude 'asset/*' \
|
||||
--exclude 'static/*' \
|
||||
--add-header 'cache-control:max-age=3600' \
|
||||
--verbose \
|
||||
"$ARTIFACT_PATH" \
|
||||
. \
|
||||
s3://dpb587-us-west-2
|
||||
|
||||
@@ -23,6 +23,8 @@ echo "--> building $ARTIFACT_BRANCH/$ARTIFACT_COMMIT..."
|
||||
|
||||
jekyll build --config _config.yml,_build/target/_config.yml
|
||||
|
||||
mv _build/target/artifact/static/dev _build/target/artifact/static/`echo $ARTIFACT_COMMIT | cut -c-10`
|
||||
|
||||
export ARTIFACT_PATH="$PWD/_build/target/artifact"
|
||||
|
||||
if [[ "" != "$1" ]] ; then
|
||||
|
||||
@@ -6,4 +6,4 @@ Publish the site:
|
||||
Create a photo gallery:
|
||||
|
||||
osascript enumerate.scpt 'London-Iceland Trip' | php -dmemory_limit=1G convert.php ~/code/dpb587.me/ 2014-london-iceland-trip
|
||||
./_build/aws/publish-asset.sh gallery/2014-london-iceland-trip
|
||||
./_build/aws/publish-asset.sh "$AWS_S3CMD_CONFIG" gallery/2014-london-iceland-trip
|
||||
|
||||
@@ -6,9 +6,9 @@
|
||||
<title>{% if page.title != "Home" %}{{ page.title }} – {% endif %}Danny Berger</title>
|
||||
|
||||
<link href="http://fonts.googleapis.com/css?family=Lato:300,400,700,300italic,400italic,700italic" rel="stylesheet" type="text/css" />
|
||||
<link href="/static/{{ site.artifact_commit|truncate:10 }}/style/default-common.css" rel="stylesheet" type="text/css" />
|
||||
<link href="/static/{{ site.artifact_commit|truncate:10 }}/style/default-print.css" media="print" rel="stylesheet" type="text/css" />
|
||||
<link href="/static/{{ site.artifact_commit|truncate:10 }}/style/pygments.css" rel="stylesheet" type="text/css" />
|
||||
<link href="/static/{{ site.artifact_commit|truncate:10,'' }}/style/default-common.css" rel="stylesheet" type="text/css" />
|
||||
<link href="/static/{{ site.artifact_commit|truncate:10,'' }}/style/default-print.css" media="print" rel="stylesheet" type="text/css" />
|
||||
<link href="/static/{{ site.artifact_commit|truncate:10,'' }}/style/pygments.css" rel="stylesheet" type="text/css" />
|
||||
<link href="/blog/atom.xml" type="application/atom+xml" rel="alternate" title="Danny Berger (blog)" />
|
||||
|
||||
{% if page.path %}
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
<a href="https://maps.google.com/maps?hl=en&ll={{ page.location.latitude }},{{ page.location.longitude }}&t=w&z=12"><img alt="map" height="49" src="https://maps.googleapis.com/maps/api/staticmap?center={{ page.location.latitude }},{{ page.location.longitude }}&zoom=9&size=98x98&sensor=false" title="{{ page.location.title }}" width="49" /></a>
|
||||
{% endif %}
|
||||
{% if page.code %}
|
||||
<a href="{{ page.code }}"><img alt="code" height="49" src="/static/{{ site.artifact_commit|truncate:10 }}/icon/code.png" width="49" /></a>
|
||||
<a href="{{ page.code }}"><img alt="code" height="49" src="/static/{{ site.artifact_commit|truncate:10,'' }}/icon/code.png" width="49" /></a>
|
||||
{% endif %}
|
||||
</div>
|
||||
<div class="social screen-only">
|
||||
|
||||
Reference in New Issue
Block a user